Activate slider function from link on previous page

Tried this:
Featured #3

Did not work.

My goal is to make this scenario work.

From this page ( link from one image in "Featured Items" ) :


This page ( remove class "hide" and slide to div id="sixteen" ) :

Is this possible? Could someone lead me in the right direction?



  • there is no element with id="sixteen"
  • Sorry.
    Looking at the HTML, near the end, you'll
    find " [code]
    [/code] "


    Will the hyperlink code that I used above work? What am I missing?

  • Sorry for the repost. Just wondering if I could get more insight on the above question?

  • Cookies are the best
    [green]WHAT you;see_is_what=you.get;[/green]
    -Russ aka DangeRuss
  • How will cookies allow the user to see this page
    [link=][/link], plus remove class "hide" and slide to div id="sixteen" after clicking
    on a link in this []page[/link]?

    I'm afraid that I don't have much practice using cookies.
    I'm I doing this correctly? Please see the following:

    [color=Orange]Page one:[/color]

    function writeCookie(templatespage, feature3button, 1)
    var expire = "";
    if(hours != null)
    expire = new Date((new Date()).getTime() + hours * 3600000);
    expire = "; expires=" + expire.toGMTString();
    document.cookie = name + "=" + escape(value) + expire;

    Featured #3


    [color=Orange]Page two[/color]

    write("$('sixteen').removeClass('hide');return false;") =
  • I'm afraid that there are two intertwined programming languages here that run on separate machines: Javascript and PHP

    javaScript is a client technology that works well with the HTML (that contains the ID attribute) and CSS (where the style is at). All of these are client technologies.

    Your server runs PHP to deliver, and collect, the content to the client computers to run the content. Although PHP can rewrite the code to be interpreted by the client computer, it is the HTML, CSS and javaScript mechanisms that load content to be displayed on the computer.

    The cookie stores a value, because the client computer doesn't keep anything on a document when the address changes and PHP sends another page.

    In your first post you attempted a to make a link to this address: [color=Grey]../main/cd-dvd-bd/index.php?$('sixteen').removeClass('hide');return false;[/color]. The problem is that the ? in the link tells php that there are additional values it should be aware of when broadcasting the code. This behavior is similar to submitting a form, whereas a cookie stays on the client computer. And the above is javaScript code that will not be understood by PHP. That is the reason I recommend cookies.

    Moving on, here is some javaScript code that might help:
    function writeCookie(name,escape)
    document.cookie = name + "=" + escape(value);

    Featured #3

    By adding the above code to page one, you inform the next page to that the cookie [italic]templatespage[/italic] has the value of the desired slider location. There is more work for the next page. Some hints: load the cookie value first so the client has a value to compare... remember these are conditional effects that you desire... the document is where the client stores the effects, so [b]document[/b] is your top level container.
    var featuredButton = readCookie('featuredButton')

    The first line in the above code is from some commented out scripts on line 325 of the second page and probably depends on the SlidingTabs object found in one of the includes from the script tags starting around line 30.

    I could go on, but this ought to get you started. I suggest a slimmed down test-bed to get the configuration right. I typically remove everything that is not neede to provide the desired effect.

Sign In or Register to comment.

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!