PDA

View Full Version : Altering a content loop script for Virtual Pagination



JBottero
06-03-2007, 01:17 AM
This script:

http://www.dynamicdrive.com/dynamicindex17/virtualpagination.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?

mburt
06-03-2007, 07:20 PM
Use the pre-built function showpage();

showpage(Math.floor(Math.random()*4))
Whereas "4" is the maximum number of pages.