Linking jQuery Cycle Pager element -
I am using the jQuery Cycle plugin with pagers. I need navigation functionality, where I can provide a link for my customer and it can browse the page which is a project gallery I need a cycle plugin to show a special slide, perhaps on a specific slide Variables can be supplied in the URL to go.
In that case, I will need to get a variable on pageload from the URL (a number 'N') and click on one of the NATH elements. Inside a div
You can use the following to get the parameter from the query string:
< Previous> function $ _GET (q, s) {s = (s)? S: window.location.search; Var re = new RegExp ('& amp; amp;' + q + '= ([^ & amp;] *)', 'i'); Return (s = s.replace (/ ^ \? /, 'Amp; amp;'). Match (again))? S = s [1]: s = ''; }
Then in the cycle declaration you can use start.slide
(assuming the parameter param_num
:
$ .cycle ({start.slide: $ _GET ('param_num'), // your remaining cycle configuration});
Note that zero -based index, so you should reflect the number given in the parameter.
Comments
Post a Comment