Results 1 to 2 of 2

Thread: Altering a content loop script for Virtual Pagination

  1. #1
    Join Date
    Mar 2006
    Posts
    41
    Thanks
    1
    Thanked 0 Times in 0 Posts

    Default Altering a content loop script for Virtual Pagination

    This script:

    http://www.dynamicdrive.com/dynamici...pagination.htm

    loops through content to display in a DIV.

    The start point is hard coded, but part of the script clearly knows how many things there is to loop through.

    Is it possible to modify this script to choose a random point of entry?

  2. #2
    Join Date
    Jul 2006
    Location
    Canada
    Posts
    2,581
    Thanks
    13
    Thanked 28 Times in 28 Posts

    Default

    Use the pre-built function showpage();
    Code:
    showpage(Math.floor(Math.random()*4))
    Whereas "4" is the maximum number of pages.
    - Mike

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
  •