include_once($_SERVER['DOCUMENT_ROOT']."/_inc/mng_cnn.php");
include_once($_SERVER['DOCUMENT_ROOT']."/_inc/functions.php");
$QS = $_SERVER['QUERY_STRING'];
$act = (isset($_REQUEST["act"])? $_REQUEST["act"]: "");
$id = (isset($_REQUEST["id"])? (int)$_REQUEST["id"]: 0);
$SCRIPT = $_SERVER['PHP_SELF'];
$cur_qs = (isset($_REQUEST["cur_qs"])? $_REQUEST["cur_qs"]: $QS);
if($SCRIPT=='/-/art/index.php'){?>
}
switch($act){
////////////////////////////////////////////////////////////////
/////////////////////// BROWSE ARTISTS /////////////////////////
////////////////////////////////////////////////////////////////
case 'cli':
$sql = "Select pk_artid, name, family, url From art_artist Where fk_catid = $id Order By family";
$rs = mysql_query($sql);
if(mysql_num_rows($rs)!=0){
$i = 0;
$td = ""; $tr = "";
while ($i < mysql_num_rows($rs)):
if(($i%5)==0 && $i!=0) {$tr .= "
$td
\n"; $td = "";}
$td .= "
".mysql_result($rs, $i, "family")." ".
mysql_result($rs, $i, "name") ." | \n";
$i++;
endwhile;
echo("
");
}
break;
////////////////////////////////////////////////////////////////
/////////////////// BROWSE CATEGORY SECTION ////////////////////
////////////////////////////////////////////////////////////////
default:
$sql = "Select * From art_category Order By cat_name";
$rs_cat = mysql_query($sql);
if(mysql_num_rows($rs_cat)!=0){
$i = 0;
$td = ""; $tr = "";
while ($i < mysql_num_rows($rs_cat)):
if(($i%3)==0 && $i!=0) {$tr .= "
$td
\n"; $td = "";}
$td .= "
"
.mysql_result($rs_cat, $i, "cat_name")." (".
mysql_result(mysql_query("Select Count(*) From art_artist Where fk_catid = ". mysql_result($rs_cat, $i, "pk_catid")), 0)
.") | \n";
$i++;
endwhile;
echo("
");
}
}
if($SCRIPT=='/-/art/index.php'){
?>
}?>