daveoffy Posted December 19, 2008 Share Posted December 19, 2008 On the index page I want it to display the 4 newest members (find out by member_id in `members`) I just need to know the outline like if(x <=3){ } or whatever the code is but don't need any echos or anything and I can figure it out from there. Quote Link to comment Share on other sites More sharing options...
ILMV Posted December 19, 2008 Share Posted December 19, 2008 SELECT * FROM members LIMIT 4 ORDER BY date_registered ASC You need to use a query like this, I cannot remember is it is ASC of DESC, but try both ILMV Quote Link to comment Share on other sites More sharing options...
daveoffy Posted December 19, 2008 Author Share Posted December 19, 2008 SELECT * FROM members LIMIT 4 ORDER BY date_registered ASC You need to use a query like this, I cannot remember is it is ASC of DESC, but try both ILMV I am 98% sure it is DESC. Thanks I will try this in like 1 second. Quote Link to comment Share on other sites More sharing options...
daveoffy Posted December 19, 2008 Author Share Posted December 19, 2008 I had to do this instead because the other one wouldn't work SELECT * FROM members ORDER BY date_registered DESC LIMIT 4 Quote Link to comment Share on other sites More sharing options...
ILMV Posted December 19, 2008 Share Posted December 19, 2008 Fair point! Happy Christmas Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.