A lot of developers are already using custom html attributes to represent data inside html elements. All the important browsers support custom attributes, even if the html page doesn’t validate. 

<div customAttribute=”customdata” > </div>

If you are going to use a custom attribute, use the following syntax and your html page will be valid in html 5

<div data-lastname=”edwards”> </div>

Use the "data-variableName" format.

You will be able to access this attributes normally with jQuery, or pure javascript now, and in the future you will be able to access the contents of the attributes with the syntax element.dataset.lastname

More info on custom data attributes in html 5:

http://dev.w3.org/html5/spec/dom.html#embedding-custom-non-visible-data

Check the complete html5 spec here: http://dev.w3.org/html5/spec/