function get_microtime(){ list($tps_usec, $tps_sec) = explode(" ",microtime()); return ((float)$tps_usec + (float)$tps_sec); } if(!isset($y)){ $y=gmdate("Y"); } $cm=date("m"); if(!isset($m)){ $m=date("m");} if($m==""){ $m=date("m");} function hexentities($str) { $return = ''; for($i = 0; $i < strlen($str); $i++) { $return .= ''.bin2hex(substr($str, $i, 1)).';'; } return $return; } ?> ///////////// DETECTION DES GENS ENLIGNE - tEST if(isset($nomc)){ //echo time(); $queryA="delete from online where nom='$nomc'"; $resultA=mysql_query($queryA); $time=time(); $query="INSERT INTO `online` (`nom`,`time`)VALUES ('$nomc','$time')"; $result=mysql_query($query); $time_gone=$time-60; $query_d="delete from online where time<'$time_gone'"; $result_d=mysql_query($query_d); } //// $num1=rand(1,9); $num2=rand(1,9); $annee_c=gmdate("Y"); ///////// if(isset($addcomment)){ if($verifadd==$produit){ //if($reponse_add==$addition){ $jour_c=gmdate("d"); $day_c=gmdate("D"); $mois_c=gmdate("m"); $annee_c=gmdate("Y"); $heure_c=gmdate("H:s:i"); //echo $heure_c; //exit(); $nom=stripslashes($nom); $query="INSERT INTO `comments` (`nom` , `email` , `url` , `comment` , `id_news`, `jour`, `mois`, `annee`, `heure` )VALUES ('$nom', '$email', '$url', '$comment', '$id_n', '$jour_c', '$mois_c', '$annee_c', '$heure_c')"; $result=mysql_query($query); /// email $comment=stripslashes($comment); $sujet="Najactribune - Commentaires "; $msg='
..........................................................
Message posté sur le Blog par '.$nom.'
---------------------------------------
Titre du post: '.$titre_em.'
'.$comment.'
-----------------------------------------
Pour acceder directement à ce post - click here
..................
..................
NT
' ; // les Headers du email $header = "Content-Type:text/html;charset=iso-8859-1\n"; $header .= "Content-Transfer-Encoding: 8bit\n"; $header .="From: commentaires@najactribune.com \n"; $header.="Reply-to:commentaires@najactribune.com \n"; $header.="Bcc:magali@najactribune.com"; //------------------------------------------------------------------------------------------------------------------------ // SENDS EMAIL //------------------------------------------------------------------------------------------------------------------------ $to="nat@doseprod.com"; // envoie par fonction email de PHP mail( $to, $sujet, $msg, $header ); ///MAIL DE SUIVI // les Headers du email $header = "Content-Type:text/html;charset=iso-8859-1\n"; $header .= "Content-Transfer-Encoding: 8bit\n"; $header .="From: commentaires@najactribune.com \n"; $header.="Reply-to:commentaires@najactribune.com \n"; //$header.="Bcc:sam@doseprod.com,joolz@doseprod.com"; $query_sj="select * from news where id_news='$id_n'"; $result_sj=mysql_query($query_sj); $val_sj=mysql_fetch_array($result_sj); $titre_sj=$val_sj["titre"]; $sujet="[Najactribune Alert] : ".$titre_sj; $msg=''.$comment.'
![]() |
|||||||||||||||
|
|||||||||||||||