Rotate Between HTML
Moderator: General Moderators
Rotate Between HTML
I am making a testimonial area and I want it to rotate between different quotes with the refresh of the page. How can I do this? I was thinking something to do with the PHP random code, but I am not very good with PHP so I wasn't sure. Thanks!
Re: Rotate Between HTML
Random != rotating. If you want random then that's pretty easy, but if you want rotating then you need to keep track of the previous testimonial and show the next one in the list.
- Jonah Bron
- DevNet Master
- Posts: 2764
- Joined: Thu Mar 15, 2007 6:28 pm
- Location: Redding, California
Re: Rotate Between HTML
You'll have to be more specific on how you have it set up so far. Do you have your testimonials stored in a database already?
Re: Rotate Between HTML
Fill an array with testimonials, shuffle() it, and pick a key.
Set Search Time - A google chrome extension. When you search only results from the past year (or set time period) are displayed. Helps tremendously when using new technologies to avoid outdated results.