Is it considered bad practice to use non-standard HTML attributes?
Posted
by user198729
on Stack Overflow
See other posts from Stack Overflow
or by user198729
Published on 2010-01-22T14:39:02Z
Indexed on
2010/04/05
8:13 UTC
Read the original article
Hit count: 242
html
|JavaScript
I find it very convenient to set arbitary attributes like:
<a stackoverflowId="123">...</a>
And in JavaScript:
var soId = $selectofA.attr('stackoverflowId'); //jQuery
Is it a good practice at all? I've never had a problem with this yet.
© Stack Overflow or respective owner