Adding a page to the DOM on the fly accessing data-values.

Adding a page to the DOM on the fly accessing data-values.

Hi, if I add a page to JQM to the DOM on the fly with append how would I access the data-attribute?

I have inserted a page titled - new_dates that in the head has a data-value of 26, but how would I get it as the way I have tried,

$('#new_dates').attr('data-value') displays as undefined.

Thanks,