❔ Get website icons from URL
Hey, so I'm currently learning C# (i have coded in other languages already) and for my first project I wanted to make a password manager.
I already kind of planned how it should work but I thought of a cool idea. In a password manager you give the website (i.e. twitter.com) and your password (then it will be saved to a text file).
What I want to do is to automatically get the icon of that website (if possible) and add it on an imagelabel (im using windows forms in visual studio).
Would that even work, and if yes, how? It may be too advanced as a beginner but I like learning like that.
11 Replies
there is a convention for those icons, they are called
favicon
the most common thing is to just serve it at your root level under favicon.ico
, but you can read the HTML to find the one used if its not there
<link rel="icon" type="image/x-icon" href="/images/favicon.ico">
as an example: https://twitter.com/favicon.icoThank you! Is there a good documentation on how to implement those icons?
what do you mean by that?
You have not mentioned anything about your program, so I don't know if its a blazor, MAUI, WPF, Avalonia, Winforms, console app etc.. and "implement" how?
the word implement leads us to believe you wanna create the icon yourself. You probably mean how to add an existing icon as favicon on your website??
answer what you're using from here @ByGoalZ
https://www.google.com/s2/favicons?domain=[the-domain]
lets you get favicons from Google cacheAnd so on
I did mention windowsforms
I meant like implementing the url in the code
that still doesnt actually mean anything
Was this issue resolved? If so, run
/close
- otherwise I will mark this as stale and this post will be archived until there is new activity.