"; exit(); } while (list($s_sid, $aid, $title, $time, $introtext, $fulltext, $comments, $counter, $topic, $informant, $notes, $hits) = mysql_fetch_row($result)) { getTopics($s_sid); formatTimestamp($time); $subject = stripslashes($subject); $introtext = stripslashes($introtext); $notes = stripslashes($notes); $introcount = strlen($introtext); $fullcount = strlen($fulltext); $totalcount = $introcount + $fullcount; $morelink = "( "; if ($fullcount > 1) { $morelink .= "".translate("Read More...")." | $totalcount ".translate("bytes more")." | "; } $count = $comments; $morelink .= "".translate("comments?")." )"; } else { if (($fullcount<1)) { if(($count==1)) { $morelink .= "\">".translate("Read More...")." | $morelink2\">$count ".translate("comment")." )"; } else { $morelink .= "\">".translate("Read More...")." | $morelink2\">$count ".translate("comment")."s )"; } } else { if(($count==1)) { $morelink .= "\">$count ".translate("comment")." )"; } else { $morelink .= "\">$count ".translate("comment")."s )"; } } } // Following two lines are for add a hit to the database $sid = $s_sid; preg_match_all("/<\s*a [^>]*?href=([^>\s]+).*?>/i", $introtext, $match, PREG_PATTERN_ORDER); $a = "0"; $i = "0"; while ($a < "10") { $url = urlencode($match[1][$i]); $introtext = ereg_replace("", "", $introtext); $a++; $i++; } preg_match_all("/<\s*a [^>]*?href=([^>\s]+).*?>/i", $notes, $match, PREG_PATTERN_ORDER); $a = "0"; $i = "0"; while ($a < "10") { $url = urlencode($match[1][$i]); $notes = ereg_replace("", "", $notes); $a++; $i++; } themeindex($aid, $informant, $datetime, $title, $counter, $topic, $introtext, $notes, $morelink, $topicname, $topicimage, $topictext, $hits); } mysql_free_result($result); include("footer.php3"); // Save referer info into the database to know who are linking us include("config.php3"); if ($httpref>0) { if($HTTP_REFERER=="" OR ereg("linuxpreview.org", $HTTP_REFERER) OR ereg("unknown", $HTTP_REREFER) OR ereg("ncc.org.ve", $HTTP_REREFER)) { } else { mysql_query("insert into referer values(NULL, '$HTTP_REFERER')"); } } ?>