mardi 15 janvier 2008
Ca slame àSaint-Marc !
Par Jean-Michel Le Baut, mardi 15 janvier 2008 à 10:54 :: Rencontres :: 1081 lectures
Les Premières L1 de l'Iroise ont participé àun atelier d'écriture avec le slameur Rouda...
class dcExtendedInfo { function getInfo($type='postcount') { global $con; switch($type) { case 'postcount': $query = 'SELECT count(*) as info from '.DB_PREFIX.'post where post_pub=1'; break; case 'commentcount': $query = 'SELECT count(*) as info from '.DB_PREFIX.'comment where comment_pub=1 and comment_trackback=0'; break; case 'tbcount': $query = 'SELECT count(*) as info from '.DB_PREFIX.'comment where comment_pub=1 and comment_trackback=1'; break; case 'viewcount': $query = 'SELECT SUM(nb_view) FROM '.DB_PREFIX.'post'; break; } $res = $con->select($query); if ($type == 'viewcount') { return($res->arry_data[0]['sum(nb_view)']); } else { return($res->arry_data[0]['info']); } } } ?>
Aller au contenu | Aller au menu | Aller à la recherche
mardi 15 janvier 2008
Par Jean-Michel Le Baut, mardi 15 janvier 2008 à 10:54 :: Rencontres :: 1081 lectures
Les Premières L1 de l'Iroise ont participé àun atelier d'écriture avec le slameur Rouda...