Forum Moderators: open

Message Too Old, No Replies

Including Random Page as part of Another Page

Need help figuring out how to insert random page via SSI

         

Ledfish

9:13 pm on Dec 17, 2006 (gmt 0)

10+ Year Member



I'm having trouble trying to work the programming of this out. I'm on an IIS platform and using ASP

I have a page with a right column.

In that right column of the page, I want be able to include one of five other pages at random.

Think of it like having 5 different versions of a navigational menu set up as different pages(i.e. menu1.asp, menu2.asp, menu3.asp and so on )and you want to randomly select one of those to use each time the page is requested.

The problem is, it can not be easily done by just including an asp code generated variable into a SSI include string.

However I have to believe that there is some kind of work around to this so that you can assemble the string.

Anybody able to help?

aspdaddy

4:53 pm on Dec 18, 2006 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



You could use a case statement with 5 options and generate a random number. In the case statements just grab the pages content using xml and write it the the screen.