<?php
	$path="../../../../";
	if(file_exists("".$path."config/map.php" )){$path2="config/"; include("".$path."config/map.php");}else{include("".$path."map.php");}
	if ($_GET["ne"] == "kayit"){ $q="u"; }elseif ($_GET["ne"] == "video"){ $q="v"; }elseif ($_GET["ne"] == "galeri"){ $q="g"; }elseif ($_GET["ne"] == "sayfa"){ $q="s"; }elseif ($_GET["ne"] == "haber"){ $q="h"; }elseif ($_GET["ne"] == "msayfa"){ $q="m"; }elseif ($_GET["ne"] == "marka"){ $q="n"; }elseif ($_GET["ne"] == "uye"){ $q="k"; }elseif ($_GET["ne"] == "reklam"){ $q="r"; }elseif ($_GET["ne"] == "forum"){ $q="f"; }
	if ($_GET["val"] == ""){ $cval="Cat_ID"; $kval="id"; }else{ $cval=$_GET["val"]; $kval=$_GET["val"]; } //Value değiştirmek gerekirse val=Cat_lang1 gibi Gönder
?>
<option value="0">...</option>
<?php if ($_GET["islem"] == "kategori"){?>
	<?php $sql=mysqli_query($conn, "select * from kategoriler where (ne='".$q."alt_kategori' and c1=".$_GET["c"].") or (ne='".$q."alt_kategori2' and c2=".$_GET["c"].") or (ne='".$q."alt_kategori3' and s3=".$_GET["c"].") or (ne='".$q."alt_kategori4' and s4=".$_GET["c"].") or (ne='".$q."alt_kategori5' and s5=".$_GET["c"].") or (t1='".$_GET["ne"]."' and s1=".$_GET["c"]." and s2=0) or (t1='".$_GET["ne"]."' and s2=".$_GET["c"]." and s3=0) or (t1='".$_GET["ne"]."' and s3=".$_GET["c"]." and s4=0) order by sira,Cat_".$_SESSION['lang']." asc"); while($rsc=mysqli_fetch_assoc($sql)){ $jsc = json_decode($rsc["n1"],true);?>
		<option value="<?php echo $rsc[$cval];?>" ID="<?php echo $rsc["Cat_ID"];?>" style="color:#6699FF"><?php if($jsc[$_SESSION['lang']]<>""){echo $jsc[$_SESSION['lang']];}else{echo $rsc["Cat_".$_SESSION['lang'].""];}?></option>
	<?php }?>
<?php }elseif ($_GET["islem"] == "kayit"){?>
	<?php $sql=mysqli_query($conn, "select * from ".$_SESSION["lang"]." where (ne='kayit' and s9='".$_GET["c"]."') or (ne='kayit' and s10='".$_GET["c"]."') order by t1 asc"); while($rsu=mysqli_fetch_assoc($sql)){ ?>
		<option value="<?php echo $rsu[$kval];?>" ID="<?php echo $rsu["id"];?>" style="color:#6699FF"><?php echo $rsu["t1"];?></option>
	<?php }?>
<?php }?>