Welcome to WebmasterWorld Guest from 50.19.34.234

Forum Moderators: incrediBILL

Message Too Old, No Replies

html5 and rel= "non-registered"

html5 rel

     

mihomes

7:39 am on Apr 29, 2012 (gmt 0)

10+ Year Member



I am in the process of changing an older xhtml strict 1.0 site to html5 doctype.

I am using a jquery modal script that allows you to click a hyperlink and popup a the image in a modal box. Problem is, at the moment the script uses a rel=blahblah to define an image that should be popped up by the script. When using the html5 doctype and validating I get an error that the rel attribute keyword is not registered. Makes sense of course, but is it okay to just go ahead and use any valid rel defined for html5 to solve the issue?

Since the defined keywords are pretty specific I do not want to run into trouble for say using something like rel=help to use the script if that makes sense. I cannot use something like title=blahblah instead as that is the popups description for the script.

Any suggestions are welcome... thanks!

mattur

6:51 pm on Apr 30, 2012 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



You could use HTML5's custom data-* attributes for this purpose:

[developers.whatwg.org...]

mihomes

3:47 am on May 1, 2012 (gmt 0)

10+ Year Member



mattur - thanks for the response. That is exactly what I ended up doing. Today I removed all rel's from my site and recoded my scripts to use the custom data-*'s... I was hesitant to do anything in html5, but since I have been coding in xhtml strict 1 for some time now to force everything to be clean there was surprisingly very few changes needed!
 

Featured Threads

Hot Threads This Week

Hot Threads This Month