Top "Custom-data-attribute" questions

Custom data attributes are intended to store custom data private to the page or application, for which there are no more appropriate attributes or elements.

removeData() jquery method not working

I think I'm using removeData correctly but it doesn't seem to be working, here's what I'm seeing in the dev …

jquery custom-data-attribute
Custom sorting on values in a data-sort attribute with Jquery Datatables

I have to do some custom sorts with Jquery Datatables. I do not want to write custom sort functions for …

jquery html sorting datatables custom-data-attribute
JQuery .data() not working?

Recently I was coding away, and I ran into a weird issue. I was attempting to assign a data attribute …

jquery custom-data-attribute
Escaping/encoding single quotes in JSON encoded HTML5 data attributes

In PHP, I use json_encode() to echo arrays in HTML5 data attributes. As JSON requires - and json_encode() …

php json html custom-data-attribute
Selecting custom data attributes in JQuery

I have a list here <ul id="demo2" data-name="demo2"> <li data-value="here">here</li&…

javascript jquery html custom-data-attribute
Pass javascript function as data-* attribute and execute

We know such syntaxes as below, when defining a value for onClick attribute: <button type="submit" onclick="alert('hi');"&…

javascript jquery custom-data-attribute
HTML 5 Browser Compatibility Chart - HTML 5 in Old Browsers?

I have just started considering using the HTML 5 api for a Rails/JQuery project, so I can use that great …

html compatibility custom-data-attribute layout-engine
jQuery - How to add HTML 5 data attributes into the DOM

I am trying to add a HTML 5 data attribute into the DOM. I have seen on the jQuery site the …

jquery html custom-data-attribute
jquery get HTML 5 Data Attributes with hyphens and Case Sensitivity

How to get data attributes using jquery .data()? In which case html5 data-* attributes converts to lowercase and camelcase? What …

jquery html custom-data-attribute jquery-data
Working with knockoutjs attr to write data* attributes

I'm running into a problem with data* attributes in knockout.js ie. writing them out with attr. I can do …

knockout.js custom-data-attribute