Hi, I have a simple problem, I'll try to explain it as best I can:
News entries in my database are ordered from oldest to newest. In order to pull out the last 10 lines I do this:
$newsquery=mysql_query("SELECT * FROM news ORDER BY timestamp DESC LIMIT 10");
while($row = mysql_fetch_array($newsquery)){
echo '<b>' .$row['line']. '</b>
';
}
It spits out something like this:
most recent news in db
second most recent news in db
third most recent news in db
etc...
The problem is I need to flip that list so the oldest of the 10 is on top and the newest is on bottom.
What I've tried:
$row = array_reverse(mysql_fetch_array($newsquery)))
array_reverse didn't seem to do anything.
I've also read that it can be done with a subquery, but the explanation wasn't that great.
Any help would be much appreciated!
Putting double spaces instead of single spaces
Im looking at trying to replace all single spacing between fields with double spacingAt present my file looks like this 3 Caxxxan Maxxxet Waxxxxe Axxxxxxy Co.Kildare but after the double spacing, I
Login Script Issues
I am using a script I got from http://phpsense.com/php/php-login-script.html in order to allow people to login but prevent multiple logins with the same username. Everything appears to work fine
Cloud Computing?
Hello,I was wondering if anyone could help explain this term to me. I'm starting to hear it a lot now. Tried looking up some definitions on it via Google and on Wikipedia but its all really technical
Default TimeZone
The server I'm working with is hosted in America so all times inserted into the database are coming out 5 hours differen't to what I want them to. I attempted placing the following in my Header
Xml parsing
I need a suggestion about parsing xml with multiply parts like pervious... i.e. different devices has a similar configuration, but how I can discern it by device? Code: <config><device
Troubles with a spider class
I am building a spider that will crawl through random whitepages (eg. anywho.com, switchboard.com, whitepages.com, etc..) and collect the information on the people found there and throw it into a
trouble printing an array....
I'm having some trouble printing out an array forwards. I'm figuring out the high and low of an array and did soo, but can't print out. My result is zero. if anyone could help that would be great, and
do while conditions
i want to display 6 images in a 2x3 tablenow what would be the correct logic tocount that there are 6 images resultsand if there are more than 6 images loop and echo the rest but not in the tablebut
does anyone know a php script to send mail using gmails/googles free smtp server
cause i heard u can do that but i dont know how
Extracting Long text from message class with parameters
Hi,