SypherGaming Posted March 14, 2011 Share Posted March 14, 2011 im wondering how to get php to read the latest row (instead of show them all) and when another one comes it replaces it once the page refreshes Link to comment https://forums.phpfreaks.com/topic/230600-mysql-and-php-rows/ Share on other sites More sharing options...
TomFromKWD Posted March 14, 2011 Share Posted March 14, 2011 personally I add: ORDER BY rowname DESC LIMIT 1 to the SELECT * code for example if you have auto_increamental ID row called ID it would be ORDER BY ID DESC LIMIT 1 and then you can change to LIMIT 2, LIMIT 3 and so on depending on how many you want it to show Link to comment https://forums.phpfreaks.com/topic/230600-mysql-and-php-rows/#findComment-1187365 Share on other sites More sharing options...
SypherGaming Posted March 14, 2011 Author Share Posted March 14, 2011 thanks i worked out what you meant by watching a video im a noob when it comes to this stuff... Link to comment https://forums.phpfreaks.com/topic/230600-mysql-and-php-rows/#findComment-1187397 Share on other sites More sharing options...
TomFromKWD Posted March 14, 2011 Share Posted March 14, 2011 you got the code working ok? I can give you a full example of what to change if you post me your existing code Link to comment https://forums.phpfreaks.com/topic/230600-mysql-and-php-rows/#findComment-1187399 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.