session_start(); header('Content-Type: text/html; charset=utf-8'); include "logs/function_2.php"; include "languages/ar.php"; define("main","true"); $type= strip_tags($_GET["type"]); $para = strip_tags($_GET["para"]); if($para !=""){ $para = strip_tags($_GET["para"]); $para = str_replace("-", " ",$para); if($type == "page"){ $q=mysqli_query2("select * from pages where page_name like '".$para."'"); $r =mysqli_fetch_array($q); $pid = $r["id"]; }elseif($type == "news"){ $q=mysqli_query2("select * from articles_cat where name like '".$para."'"); $r =mysqli_fetch_array($q); $pid = $r["id"]; }elseif($type == "new"){ $q=mysqli_query2("select * from articles where name like '".$para."'"); $r =mysqli_fetch_array($q); $pid = $r["id"]; } } ///////////////////////////////////////// Page id $pid = strip_tags($pid); if($pid =="20"){ $param = $label_home; }elseif($type =="page"){ $qp = mysqli_query2("select * from pages where id='".$pid."'"); $rp = mysqli_fetch_array($qp); $pid = $rp["id"]; $param = $rp["page_name".$ext]; $description_face = $BaseMain->strword($rp["text".$ext],30); $image_face = "https://www.economy2day.com/pages/photos/".$rp["src"]; }elseif($type =="news"){ $qp = mysqli_query2("select * from articles_cat where id='".$pid."'"); $rp = mysqli_fetch_array($qp); $pid = $rp["id"]; $param = $rp["name".$ext]; $description_face = $BaseMain->strword($rp["text".$ext],30); $image_face = "https://www.economy2day.com/articles_cat/photos/".$rp["src"]; }elseif($type =="new"){ $qp = mysqli_query2("select * from articles where id='".$pid."'"); $rp = mysqli_fetch_array($qp); $pid = $rp["id"]; $param = $rp["name".$ext]; $description_face = $BaseMain->strword($rp["text".$ext],30); $image_face = "https://www.economy2day.com/articles/photos/".$rp["src"]; }elseif($type =="currency"){ $param = "أسعار العملات"; }elseif($type =="metal"){ $param = "أسعار المعادن"; }elseif($type =="material"){ $param = "أسعار المواد"; }elseif($type =="news" && $_GET["param"] !=""){ $param = $_GET["param"]; }else{ $param = $label_home; } ?>
if($_SERVER["HTTP_HOST"] == "localhost"){ $base = "http://localhost/economyday.com/"; }else{ $base = "https://www.economy2day.com/"; } ?>