require($_SERVER['DOCUMENT_ROOT'] . '/config/mysql_config.php');
$connection_mysql = mysql_connect($mysql_host,$mysql_login,$mysql_password);
mysql_select_db($mysql_base);
$res = @mysql_query("SELECT COUNT(*) FROM tags WHERE status='1' AND buyhits>totalhits") or die('Erreur : '.mysql_error());
list($count_tags) = @mysql_fetch_row($res);
$res = mysql_query("SELECT content FROM options WHERE type='nb_imp'");
$nb_imp = mysql_result($res, 0, "content");
$res = mysql_query("SELECT content FROM options WHERE type='nb_clicks'");
$nb_clicks = mysql_result($res, 0, "content");
echo(" Actuellement $count_tags tags actifs sur le réseau ");
$list_tags_pointer = mysql_query("SELECT `id`, `usrid`, `name`, `color`, `flyover`, `url` FROM `tags` WHERE buyhits > totalhits AND status='1' ORDER BY RAND() LIMIT 50");
while ($list_tags = mysql_fetch_array($list_tags_pointer)) {
$tag_id=$list_tags['id'];
$tag_usrid=$list_tags['usrid'];
$tag_name=$list_tags['name'];
$tag_name_url=urlencode($tags_name);
$tag_flyover=$list_tags['flyover'];
$tag_color=$list_tags['color'];
$res = mysql_query("SELECT content FROM options WHERE type='click_code'");
$click_code = mysql_result($res, 0, "content");
$sign_code = md5($click_code.$tag_id);
if($tags_flyover == ""){$tags_flyover = $tags_name;}
echo("");
echo("$tag_name");
echo(" \n");
}
mysql_close;
/*
|
$rand = rand(1, 2);
if($rand == '1') { echo("Les tags ont été affichés $nb_imp fois depuis le 17/06/2008"); } elseif($rand == '2') { echo("Les tags ont été cliqués $nb_clicks fois depuis le 17/06/2008"); } ?> |
*/
?>
|