Tutorials
Display number of fanlistings you run
-
Display number of fanlistings you run
Posted on May 25, 2004
Written by
Sasha (view more by Sasha)
Comments (0)
Filed under Scripts: Flinx, Tutorials
You can display the number of the fanlistings you own and their categories in your collective’s main page. I use it in my fanlisting collective to show my visitors the statistics.
To display the number of fanlistings:
<?php
include_once("config.php");
$query = "SELECT linkID FROM $table_link";
$result = mysql_query($query);
$num_link = mysql_numrows($result);
?><strong><?php echo $num_link; ?></strong>
To display the number of categories you have:
<?php
include_once("config.php");
$query = "SELECT catID FROM $table_cat";
$result = mysql_query($query);
$num_cat = mysql_numrows($result);
?><strong><?php echo $num_cat; ?></strong>
If you separated Flinx collective in a subdirectory, simply add that in the include("flinx_collective_folder/config.php");
Comments
Comments are closed for this entry.