Set a cookie.
next page, load the cookie, depending on logic do something (your 1, 2/4/5, 3, 2/4/5, 1, etc).
Set the cookie.
Repeat
JQuery can be used to set the meta refresh.
Or set a window.timeout upon document ready to redirect to the next page, again using the cookies idea to store the value of the last/next page.
hope that helps, should be easy to find example code, google:
jquery set cookie
jquery set meta refresh
jquery change url
etc
