="0"){ $id=filter_var($_GET['id'], FILTER_VALIDATE_INT); /* $expire=time()-2592000; // valable dix minutes $expires=2592000; $cache=($_SERVER['DOCUMENT_ROOT']."/_cache/page-".$id.".html"); if(file_exists($cache)){ $size=filesize($cache);header("Content-Length:$size"); }else{} header('Expires:' . gmdate('D, d M Y H:i:s', time()+$expires) . ' GMT, +1'); if(file_exists($cache) && filemtime($cache)>$expire && $size!="0"){ ob_start("ob_gzhandler_no_errors"); header("Last-Modified:".gmdate("D, d M Y H:i:s", filemtime($cache))." GMT, +1"); readfile($cache); }else{ ob_start(); */ include($_SERVER['DOCUMENT_ROOT']."/test/databases/4/db_eyar.php"); include($_SERVER['DOCUMENT_ROOT']."/test/databases/4/db_vekirin.php"); function dateaffichee($time, $mode = 'long' ) { setlocale( LC_TIME, "fr" ); // Recuperation du nom du mois $mi = strftime( "%m" , strtotime( $time ) ); switch ($mi){ case '1' : $mi = 'janvier'; break; case '2' : $mi = 'février'; break; case '3' : $mi = 'mars'; break; case '4' : $mi = 'avril'; break; case '5' : $mi = 'mai'; break; case '6' : $mi = 'juin'; break; case '7' : $mi = 'juillet'; break; case '8' : $mi = 'août'; break; case '9' : $mi = 'septembre'; break; case '10' : $mi = 'octobre'; break; case '11' : $mi = 'novembre'; break; case '12' : $mi = 'decembre'; break; } // Recuperation du nom du jour $w = strftime( "%u" , strtotime( $time ) ); switch ($w){ case '1' : $w = 'Lundi'; break; case '2' : $w = 'Mardi'; break; case '3' : $w = 'Mercredi'; break; case '4' : $w = 'Jeudi'; break; case '5' : $w = 'Vendredi'; break; case '6' : $w = 'Samedi'; break; case '7' : $w = 'Dimanche'; break; } // Recuperation du jour $mor1 = strftime( "%e " , strtotime( $time ) ); // Recupera de l'année $mor2 = strftime( "%Y" , strtotime( $time ) ); if ( $mode == 'long' ) { // Recupere de l'heure+minute+seconde $mor3 = strftime( "à %Hh%M" , strtotime( $time ) ); //$mor3 = strftime( "à %Hh %Mm %Ss" , strtotime( $time ) ); }else{ $mor3 = NULL; } return $w.' '.$mor1.' '. $mi. ' '.$mor2. ' '.$mor3; //return $w.' '.$mor1.' '. $mi. ' '.$mor2. ' '.$mor3; } /* AND lng='1' */ if(isset($id) && strlen($id)>="1"){ $query=("SELECT * FROM newsarticles WHERE status='1' AND id=".$id.""); $result = mysql_query("$query") or die(mysql_error()); $num_rows = mysql_num_rows($result); if($num_rows=='1'){ $id=mysql_result($result,0,"id"); $title=mysql_result($result,0,"title"); $head=mysql_result($result,0,"head"); $full=mysql_result($result,0,"full"); $category=mysql_result($result,0,"category"); $added=mysql_result($result,0,"added"); $status=mysql_result($result,0,"status"); $redirect=mysql_result($result,0,"redirect"); $showfiles=mysql_result($result,0,"showfiles"); if($redirect!=NULL){ header("HTTP/1.1 301 Moved Permanently"); header("Location: ".$redirect); exit; } $head=stripslashes($head); $full=stripslashes($full); if($status=='1'){ include($_SERVER['DOCUMENT_ROOT']."/x_html.php"); $keywordhead=strip_tags($head); //$keywordhead=dateaffichee($added)." - ".htmlspecialchars($keywordhead, ENT_QUOTES); $keywordhead=dateaffichee($added)." - ".substr($keywordhead, 0, 200)."..."; $xtitle=htmlspecialchars($title); $xdescription="$keywordhead"; $xkeywords="$keywordhead"; function fbimagepresent($id){ include($_SERVER['DOCUMENT_ROOT']."/test/databases/new/db_eyar.php"); include($_SERVER['DOCUMENT_ROOT']."/test/databases/new/db_vekirin.php"); $query=("SELECT * FROM newsmedia where nid='".$id."' AND type LIKE '%image%' order by rank ASC"); $result = mysqli_query($conn,$query) or die(mysqli_error($conn)); $num_rows = mysqli_num_rows($result); if($num_rows=='1'){ $data = mysqli_fetch_object($result); $id=$data->id; $img="https://www.nazandbegikhani.com/info/images/crop/photo-270X181-".$id.".jpg"; } return $img; } $fbimage=fbimagepresent($id); include($_SERVER['DOCUMENT_ROOT']."/x_meta.php"); ?> ".$title." - Nazand Begikhani"; include($_SERVER['DOCUMENT_ROOT']."/x_header.php"); function categoryname($category){ $query=("SELECT * FROM newscats WHERE cid='".$category."'"); $result = mysql_query($query) or die(mysql_error()); $num_rows = mysql_num_rows($result); $cid=mysql_result($result,0,"cid"); $cat=mysql_result($result,0,"cat"); $navnisan=mysql_result($result,0,"navnisan"); return $cat; } echo"
"; echo "

".categoryname($category)."

"; /* if($added=="0000-00-00 00:00:00"){ }else{ echo "

mis à jour le ".dateaffichee($added)."

"; } */ echo"
"; echo"
"; function category($category){ $query=("SELECT * FROM newscats WHERE cid='".$category."'"); $result = mysql_query($query) or die(mysql_error()); $num_rows = mysql_num_rows($result); $cid=mysql_result($result,0,"cid"); $cat=mysql_result($result,0,"cat"); $navnisan=mysql_result($result,0,"navnisan"); echo "".$cat.""; } echo"
"; echo"

$title

"; function resimler($id){ include($_SERVER['DOCUMENT_ROOT']."/test/databases/4/db_eyar.php"); include($_SERVER['DOCUMENT_ROOT']."/test/databases/4/db_vekirin.php"); $query=("SELECT * FROM newsmedia where nid='$id' AND type LIKE '%image%' order by rank ASC"); //echo $query; $result = mysql_query($query) or die(mysql_error()); $num_rows = mysql_num_rows($result); if($num_rows==true){ //$filetype=mysql_result($result,0,"type"); echo"
"; while ($row=mysql_fetch_array($result)) { echo""; echo"\"".$row[7]."\""; echo""; //echo"

".$row['legende']."

"; } echo"
"; } include($_SERVER['DOCUMENT_ROOT']."/test/databases/4/db_girtin.php"); } if($showfiles=="1"){ resimler($id); } echo $head; function wp($id){ if($id=="46"){ function distinctwp(){ include($_SERVER['DOCUMENT_ROOT']."/test/databases/4/db_eyar.php"); include($_SERVER['DOCUMENT_ROOT']."/test/databases/4/db_vekirin.php"); $query=("SELECT distinct d.dwp, u.groupname,u.leader,u.groupdesc FROM delivinfo d, usergroups u WHERE d.dwp=u.wpid ORDER by groupname ASC"); //echo $query; $result=mysql_query("$query") or die(mysql_error()); $num_rows=mysql_num_rows($result); if($num_rows==true){ echo ""; echo ""; $counter="0"; while($row = mysql_fetch_array($result)){ $titre=html_entity_decode($row['1'], ENT_COMPAT, 'utf-8'); $titre=htmlentities($titre, ENT_COMPAT, 'utf-8'); $counter=$counter+1; echo""; echo""; } echo"
Groupes de travailLeader / Objectifs
".$titre."".$row['2']; /* if($row['3']==true){ echo"
".$row['3']."
"; } */ echo"
"; } mysql_free_result($result); } echo distinctwp(); } } echo wp($id); //echo "
"; echo $full; echo "
"; function fichiers($id){ include($_SERVER['DOCUMENT_ROOT']."/test/databases/4/db_eyar.php"); include($_SERVER['DOCUMENT_ROOT']."/test/databases/4/db_vekirin.php"); //$query=("SELECT * FROM newsmedia where `type` NOT LIKE 'image/%' AND nid='$id' order by titre"); $query=("SELECT * FROM newsmedia where `type` NOT LIKE 'image/%' AND nid='$id' order BY LENGTH(titre), titre"); //echo $query; $plus_photos=mysql_query($query); $hucre_sayisi=mysql_num_rows($plus_photos); if($hucre_sayisi==true){ echo"
"; if($hucre_sayisi=="1"){ echo"
Ci-dessous le fichier lié:
"; }else{ echo"
Ci-dessous les fichiers liés:
"; } echo"
    "; while ($row=mysql_fetch_array($plus_photos)) { $filetype=$row['type']; $filesize=$row['size']; if ($filesize>=1024){ $filesize=round($filesize/1024,2); $filesize=round($filesize/1024,2); $filesized=$filesize." MB"; }else{ if ($filesize>=1){ $filesized=$filesize." KB"; }else{ $filesize=$filesize*1000; $filesized="~".$filesize." B"; } } switch($filetype){ case "application/download"; case "application/pdf"; $downloadfileurl=($_SERVER['DOCUMENT_ROOT']."/images/mediapdf/".$row['randomid'].".pdf"); if(file_exists($downloadfileurl)){ $downloadfileurl=("/images/mediapdf/".$row['randomid'].".pdf"); }else{ $downloadfileurl=("/images/mediapdf/fichier.php?id=".$row['randomid'].""); } echo"
  • ".$row['titre']."

    ".$filesized."

  • "; break; } /* fichier.php?id=".$row['randomid']." */ if($filetype!="application/pdf"){ switch($filetype){ case "application/rtf": $ext="rtf"; break; case "application/doc": $ext="doc"; break; case "application/docx": $ext="docx"; break; case "application/dot": $ext="dot"; break; case "application/plain": $ext="txt"; break; case "application/vnd.ms-excel": $ext="xls"; break; case "application/vnd.ms-excel": $ext="xlsx"; break; case "application/msword": $ext="doc"; break; case "text/plain": $ext="txt"; break; case "application/xlsx": $ext="xlsx"; break; } echo"
  • ".$row['titre']."

    ".$filesized."

  • "; } } echo"
"; echo"
"; } include($_SERVER['DOCUMENT_ROOT']."/test/databases/4/db_girtin.php"); } fichiers($id); echo "
"; echo "
"; echo "
"; function listdecategoriesimg($id){ include($_SERVER['DOCUMENT_ROOT']."/test/databases/new/db_eyar.php"); include($_SERVER['DOCUMENT_ROOT']."/test/databases/new/db_vekirin.php"); $query=("SELECT * FROM newsmedia where nid='".$id."' AND type LIKE '%image%' order by rank ASC"); $result = mysqli_query($conn,$query) or die(mysqli_error($conn)); $num_rows = mysqli_num_rows($result); if($num_rows=='1'){ $data = mysqli_fetch_object($result); $id=$data->id; $img="https://www.nazandbegikhani.com/info/images/crop/photo-270X181-".$id.".jpg"; } return $img; } function listdecategories($category){ include($_SERVER['DOCUMENT_ROOT']."/test/databases/4/db_eyar.php"); include($_SERVER['DOCUMENT_ROOT']."/test/databases/4/db_vekirin.php"); $query=("SELECT * FROM newsarticles WHERE status='1' AND category='".$category."' order by classement ASC"); $result=mysql_query($query) or die(mysql_error($query)); $num_rows=mysql_num_rows($result); if($num_rows==true){ while($row = mysql_fetch_array($result)){ echo"
  • "; } } } echo"

    ".categoryname($category)."

      "; echo listdecategories($category); echo"
    "; ?>
    "; echo "
    "; include($_SERVER['DOCUMENT_ROOT']."/x_footer.php"); include($_SERVER['DOCUMENT_ROOT']."/test/databases/4/db_girtin.php"); } }else{ header("HTTP/1.1 301 Moved Permanently"); header("Location: /info/"); } }else{ header("HTTP/1.1 301 Moved Permanently"); header("Location: /info/"); } /* $tampon = ob_get_contents(); $tampon = str_replace(array("\n", "\r", "\t"), "", $tampon); file_put_contents("$cache", $tampon) ; //pour une meilleure organisation, on créera un répertoire cache pour y stocker les fichiers du cache ob_end_clean(); // toujours fermer et vider le tampon header("Refresh: 1; URL=".$_SERVER['REQUEST_URI']); } */ }else{ header("HTTP/1.1 301 Moved Permanently"); header("Location: /info/"); exit; } ?>