Jump to content

New topic ends up on the last page...


Gubbins

Recommended Posts

Hi,

 

This piece on sql ends up putting a new topic on the last page, is there anychance it can be altered so that a new topic is on the first page?

 

$query = mysql_query("SELECT * FROM topics WHERE forum = '$forum' ORDER BY `s` DESC, lastreply DESC LIMIT $forum_look , $forum_count")or die("Couldn't get topics:" .mysql_error());
$num = mysql_num_rows($query);

Link to comment
https://forums.phpfreaks.com/topic/198553-new-topic-ends-up-on-the-last-page/
Share on other sites

Hi,

 

This piece on sql ends up putting a new topic on the last page, is there anychance it can be altered so that a new topic is on the first page?

 

$query = mysql_query("SELECT * FROM topics WHERE forum = '$forum' ORDER BY `s` DESC, lastreply DESC LIMIT $forum_look , $forum_count")or die("Couldn't get topics:" .mysql_error());
$num = mysql_num_rows($query);

 

Not very descriptive what is s? and what values does lastreply hold?

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.