assign("sitename","xxx"); // Get Page Header $traidnt->assign('subtitle',"الصفحة الرئيسية"); $traidnt->display('header.htm'); //Get Right & Left Bloc require_once("./bloc/rightbloc.php"); require_once("./bloc/leftbloc.php"); // Get New Pic $query = $db->query("SELECT * FROM `images` ORDER BY `images`.`image_id` DESC LIMIT 9"); while($fetch = $db->fetchRow($query) ){ $newpic[] = $db->record; } $traidnt->assign('newpic',$newpic); /*Get Most Popular Tags From Db*/ $gettag = $db->query("SELECT `tag_word`, `tag_count` FROM `tags` ORDER BY `tag_count` DESC LIMIT 30"); while ($row = mysql_fetch_array($gettag)) { $term = $row['tag_word']; $counter = $row['tag_count']; $terms[] = array($term => $counter); } $maximum = @max($terms); $maximum = @max($maximum); @shuffle($terms); $traidnt->assign("taglist",Tags()); /*Get Most Popular Tags From Db*/ // Get Home Page $traidnt->display('homepage.htm'); // Get Page Footer $traidnt->display('footer.htm'); $db->clear($query); $db->clear($gettag); $db->disconnect(); $db->showErrors(); ob_end_flush(); ?>