Shuffle through news articles

In this board you can talk about general questions about phpMyFAQ

Moderator: Thorsten

Post Reply
techfaqhelp
Posts: 4
Joined: Wed Jun 15, 2011 5:46 pm

Shuffle through news articles

Post by techfaqhelp »

We would like to be able to shuffle through the news articles, so we would have it show 3/5 news items at one time. When the page is refreshed it would randomly display another 3 articles, etc.

How could that be accomplished using the php array randomize function?
http://www.php.net/manual/en/function.array-rand.php

Does anyone have any ideas on where I can start? I created a test page and was able to get the php function to work by itself, but I cannot find where in phpmyfaq the array is built with the news articles. Any tips are appreciated!

Many, Many thanks!
Thorsten
Posts: 15725
Joined: Tue Sep 25, 2001 11:14 am
Location: #phpmyfaq
Contact:

Re: Shuffle through news articles

Post by Thorsten »

Hi,

check the file news.php and the class inc/News.php

bye
Thorsten
phpMyFAQ Maintainer and Lead Developer
amazon.de Wishlist
Post Reply