zurb/foundation — Issue #118: Trying to navigate Orbit with custom code
Author: xazinji
Created: 2011-11-24 00:22:08+00:00
State: open

Cuz I need an orbit slider and the navigation of that slider in a different part of the site, I was trying something with jQuery and I did manage to change to the correct slide with the correct link by adding some classes to both the slides and the navigation links, but it breaks the sliding of orbit and keeps the slide selected by the link on top. Here's what I did with my script.

jq("#featured-content-nav a").click(function() {
var getLinkNum = jq(this).attr("class");
var getFragment = "#featured-content-main img." + getLinkNum;
jq(getFragment).css("z-index", "100");
return false;
});

This changes the z-index, bringing the right slide to the front, but this obviously broke orbit. Any other way of doing this?