jquery - html string into css - how to? -


i using plax jquery plugin, uses html-string: data-xrange="" data-yrange=""

here's fiddle of project: http://jsfiddle.net/4krdl/

i responsive, i've did. problem now, when window minimized, data-xrange="" data-yrange=""-string makes elements move much, because of window size.

i not great @ jquery here's question(s): possible adjust data-xrange="" data-yrange="" either css or jquery? , how done?

if element has id (or class - doesn't matter), jquery , change attribute:

$('#your-element')     .attr('data-xrange', 'new value')     .attr('data-yrange', 'new value');  // can dynamically redefine range of layer // running plaxify() on again. $('#your-element').plaxify(); 

Comments

Popular posts from this blog

c++ - Function signature as a function template parameter -

algorithm - What are some ways to combine a number of (potentially incompatible) sorted sub-sets of a total set into a (partial) ordering of the total set? -

How to call a javascript function after the page loads with a chrome extension? -