I used "bunghole" as link portal but there is something wrong. Last 3 links added does't show the last 3 added, but the first 3 on the last day of modification.
can anyone help me to fix it?
make_title("Last 3 links added");
do {
echo "<A HREF=http://www.htmlforums.com/archive/index.php/\"jump.php3?id=".$result["id"]."\" target=\"_blank\">".ucfirst($result["title"])."</A>";
echo " from <A HREF=http://www.htmlforums.com/archive/index.php/\"index.html?showcat=",withpavla($result["category"]),"\">",$result["category"],"</A> category.\n";
echo "<BR>".$result["description"]."\n";
echo "<BR>(Added: ".convert_date($result["date_added"]).", ".$result["hits"]." hits)\n";
echo "<BR>Rating: ", $result["rating"]/100,"/10 from ".$result["votes"]." votes. [<A HREF=http://www.htmlforums.com/archive/index.php/\"rate.php3?id=".$result["id"]."\">Rate It</A>]\n";
echo "<BR> <BR>";
} while(($result = mysql_fetch_array($query)));
?>
<?php else: ?>
<?php
// Set default variable values, if they're not given as parameters
if(!$order)
$order = "title";
if(!$start)
$start = 0;Oke... I was searching at the wrong spot...
$query = mysql_query("SELECT id, title, description, category, date_added, hits, is_new, rating, votes FROM bunghole_links ORDER BY date_added DESC LIMIT 3");
$result = mysql_fetch_array($query);
And I've fixed the problem by changing 'ORDER BY date_added' into 'ORDER BY id'
can anyone help me to fix it?
make_title("Last 3 links added");
do {
echo "<A HREF=http://www.htmlforums.com/archive/index.php/\"jump.php3?id=".$result["id"]."\" target=\"_blank\">".ucfirst($result["title"])."</A>";
echo " from <A HREF=http://www.htmlforums.com/archive/index.php/\"index.html?showcat=",withpavla($result["category"]),"\">",$result["category"],"</A> category.\n";
echo "<BR>".$result["description"]."\n";
echo "<BR>(Added: ".convert_date($result["date_added"]).", ".$result["hits"]." hits)\n";
echo "<BR>Rating: ", $result["rating"]/100,"/10 from ".$result["votes"]." votes. [<A HREF=http://www.htmlforums.com/archive/index.php/\"rate.php3?id=".$result["id"]."\">Rate It</A>]\n";
echo "<BR> <BR>";
} while(($result = mysql_fetch_array($query)));
?>
<?php else: ?>
<?php
// Set default variable values, if they're not given as parameters
if(!$order)
$order = "title";
if(!$start)
$start = 0;Oke... I was searching at the wrong spot...
$query = mysql_query("SELECT id, title, description, category, date_added, hits, is_new, rating, votes FROM bunghole_links ORDER BY date_added DESC LIMIT 3");
$result = mysql_fetch_array($query);
And I've fixed the problem by changing 'ORDER BY date_added' into 'ORDER BY id'