Jump to content

[SOLVED] Randomly displaying an array


rachelk

Recommended Posts

I'm a beginner at php so I apologise if I'm not making much sense here!

 

I have an array that I'd like to be ordered randomly (not just ordered randomly and then stuck that way forever, but shuffled on each visit). The array is paginated though, so if I use the "shuffle ($objects)" function, when I go to the second page everything is shuffled all over again and sometimes the objects that appeared on the first page also appear on the subsequent page.. I'm wondering if there was any way to prevent this happening?

 

Thanks in advance for any help.

Link to comment
https://forums.phpfreaks.com/topic/167572-solved-randomly-displaying-an-array/
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.