File: /home/httpd/html/baretube.com/channels.php
<?
include('admin/db.php');
session_start();
/**************************************************/
$title = 'Channels';
$headertitle = 'Channels';
$metakeywords = 'Channels page at '.$sitename;
$metadescription = 'categories for tube videos';
/***********DO NOT EDIT BELOW THIS LINE************/
$cacheName = $_SERVER[REQUEST_URI];
$cacheResult = getCache($cacheName);
if($cacheResult) {
$array = $cacheResult;
}
else {
$result = mysql_query("SELECT niches.name, niches.record_num FROM niches ORDER BY name ASC");
while($row = mysql_fetch_assoc($result)) {
$array[] = $row;
}
setCache($cacheName,$array,$overall_cache_time);
}
$thisfile = 'channels';
$ads = getAdsIndex($_REQUEST[channel]);
if($isMobile) {
include($basepath.'/templates/mobile.overall_header.php');
}
else {
include($basepath.'/templates/template.overall_header.php');
}
if(is_array($array)) {
foreach($array as $row) {
include($basepath.'/templates/template.channel_item.php');
}
}
else {
echo "Sorry, no videos were found.";
}
if($isMobile) {
include($basepath.'/templates/mobile.overall_footer.php');
}
else {
include($basepath.'/templates/template.overall_footer.php');
}
exit();
?>