FUDforum
Fast Uncompromising Discussions. FUDforum will get your users talking.

Home » FUDforum Development » Bug Reports » ALT tags on Avatars and Flags
Show: Today's Messages :: Polls :: Message Navigator
Switch to threaded view of this topic Create a new topic Submit Reply
ALT tags on Avatars and Flags [message #34952] Mon, 27 November 2006 10:43 Go to next message
Ernesto is currently offline  Ernesto   Sweden
Messages: 413
Registered: August 2005
Karma: 0
Senior Member
It's easy to add an ALT tag just to the template for the flags, but the Avatar is harder since the whole URL appears to be in the database

Re: ALT tags on Avatars and Flags [message #34953 is a reply to message #34952] Mon, 27 November 2006 10:48 Go to previous messageGo to next message
Ernesto is currently offline  Ernesto   Sweden
Messages: 413
Registered: August 2005
Karma: 0
Senior Member
So on line 209 in register.php.t
change
		return '<img src="'.$web . $path.'" '.$img_info[3].' />';


to
		return '<img src="'.$web . $path.'" '.$img_info[3].' alt="Avatar" />';


Re: ALT tags on Avatars and Flags [message #34954 is a reply to message #34952] Mon, 27 November 2006 11:15 Go to previous messageGo to next message
Ernesto is currently offline  Ernesto   Sweden
Messages: 413
Registered: August 2005
Karma: 0
Senior Member
Thinking of it, I am thinking that the template for the avatar should looks something like this instead:

<img src="{VAR: avatar_loc}" alt="{VAR: usr->Alias}'s Avatar">

Instead of having the whole <img src=" thing in the database. Changing it to the above way that I suggested allows you to add a border around the avatar in your skin/Theme, etc etc.


Re: ALT tags on Avatars and Flags [message #34955 is a reply to message #34952] Mon, 27 November 2006 11:15 Go to previous messageGo to next message
Ernesto is currently offline  Ernesto   Sweden
Messages: 413
Registered: August 2005
Karma: 0
Senior Member
And of course do the {IF} check first to see if we use embed or img

Re: ALT tags on Avatars and Flags [message #34960 is a reply to message #34955] Mon, 27 November 2006 23:50 Go to previous messageGo to next message
Ilia is currently offline  Ilia   Canada
Messages: 13241
Registered: January 2002
Karma: 0
Senior Member
Administrator
Core Developer
Flags use title attribute which is MUCH better then alt, since unlike alt titles are displayed on mouseover.

As far as avatars go, what purpose would the alt tag serve there?


FUDforum Core Developer
Re: ALT tags on Avatars and Flags [message #34963 is a reply to message #34952] Tue, 28 November 2006 00:25 Go to previous messageGo to next message
Ernesto is currently offline  Ernesto   Sweden
Messages: 413
Registered: August 2005
Karma: 0
Senior Member
To be valid HTML 4.01 Transitional.

And the ALT tag shows on mouseover in IE, while title only shows in Firefox (thats how it used to be at least, I could be wrong now) - But mainly it was for validation purposes.

But yes, I like the title tags, but perhaps you should have both.


[Updated on: Tue, 28 November 2006 00:26]

Report message to a moderator

Re: ALT tags on Avatars and Flags [message #34968 is a reply to message #34963] Tue, 28 November 2006 15:14 Go to previous message
Ilia is currently offline  Ilia   Canada
Messages: 13241
Registered: January 2002
Karma: 0
Senior Member
Administrator
Core Developer
Quote:


And the ALT tag shows on mouseover in IE, while title only shows in Firefox (thats how it used to be at least, I could be wrong now) - But mainly it was for validation purposes.



That mostly correct, IE will also show the title tag, which is why I have been using it throughout the forum. The reason why I don't use both tags is because usage of both will inflate page sizes with no apparent benefit other then syntactic sugar.


FUDforum Core Developer
  Switch to threaded view of this topic Create a new topic Submit Reply
Previous Topic: Sort by flag
Next Topic: Action Log Viewer bug
Goto Forum:
  

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ]

Current Time: Thu Nov 21 13:54:15 GMT 2024

Total time taken to generate the page: 0.04840 seconds