Results 1 to 2 of 2

Thread: Calling Content Slider pages with a dynamic name rather than the page number?

  1. #1
    Join Date
    Sep 2010
    Posts
    19
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default Calling Content Slider pages with a dynamic name rather than the page number?

    1) Script Title: Content Slider

    2) Script URL (on DD): http://www.dynamicdrive.com/dynamici...tentslider.htm

    3) Describe problem: I need to call content from an external page where I do not know the order of the content. Currently the script info says it must be linked like so: targetpage.htm?sliderid=pagenumber

    where "sliderid" is the ID of the Featured Content instance on the page, and "pagenumber" is an integer for the slide you wish to be shown (1=1st page, 2=2nd etc)


    However, instead of the integer can I add in the <div> a specific id such as <div class="contentdiv" id="This-Page-Is"> and then call from the external source like so: targepage.html?sliderid=This-Page-Is rather than the 1=1st page, etc.

    Any ideas? Thanks!

  2. #2
    Join Date
    Aug 2004
    Posts
    10,143
    Thanks
    3
    Thanked 1,008 Times in 993 Posts
    Blog Entries
    16

    Default

    Try the below attached .js file. It should let you do something like:

    Code:
    mypage.htm?sliderid=divid
    where divid is the ID of the content DIV within the slider you wish to be selected when the page loads, ie:

    Code:
    <div id="slider1" class="sliderwrapper">
    
    <div class="contentdiv">
    Content 1 Here. <br />
    <p></p><a href="javascript:featuredcontentslider.jumpTo('slider1', 3)">Go to 3rd slide</a></p>
    </div>
    
    <div class="contentdiv">
    Content 2 Here.
    </div>
    
    <div class="contentdiv" id="thirddiv">
    Content 3 Here.
    </div>
    
    </div>
    
    <div id="paginate-slider1" class="pagination">
    
    </div>
    DD Admin

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •