I have a page full of user-submitted updates and stuff. Basically the basic stuff. I am taking it out of a database. I have this so far:
$getnews = mysql_query("SELECT * FROM news ORDER BY $order LIMIT 50");
and $order is determined by a drop down menu on the top of the page. That drop down menu includes an option to view most "liked" (determined by a column of the database table that shows how many people have liked the post.
I do not want it to be the top 50 most liked of all time, though (which is what it's currently doing), I want the ability ot have the most liked OF the top 50 (like, take the last 50 postings, sort by most liked), but when I try to put LIMIT 50 before ORDER BY, it gives me an error. Any help?