",$sbmessage); $sbmessage = str_replace(chr(13),"
",$sbmessage); $sbmessage = str_replace(chr(10),"
",$sbmessage); $sbmessage = str_replace(";",",",$sbmessage); if(preg_match("true",$plugin_cf['sblog']['cleanText'])){ $sbmessage = sb_cleantext(stripslashes($sbmessage)); } if (!$fp = fopen($sbfile, 'a')) { $tvari.="
ERROR: Cannot open file ($sbfile)"; } else { setlocale(LC_TIME, $plugin_tx['sblog']['loc_date1'], $plugin_tx['sblog']['loc_date2'], $plugin_tx['sblog']['loc_date3']); /* localisation de la date */ if(preg_match("true",$plugin_cf['sblog']['record_Release'])){ $sbentry = "\n##" . $sbname .";". $sbemail .";". $sbwebsite .";". date($plugin_cf['sblog']['time_format']) .";". strftime($plugin_cf['sblog']['date_format']) .";". $sbimage .";". $sbmessage .";". $_SERVER["REMOTE_ADDR"] . ";[END OF RECORD]"; } else { $sbentry = "\n" . $sbname .";". $sbemail .";". $sbwebsite .";". date($plugin_cf['sblog']['time_format']) .";". strftime($plugin_cf['sblog']['date_format']) .";". $sbimage .";". $sbmessage .";". $_SERVER["REMOTE_ADDR"] . ";[END OF RECORD]"; } if ($plugin_cf['sblog']['emailNotice'] !=="") { //////////////////////////////////////////////////// //Mailer: // $kopf = $plugin_tx['sblog']['mail_header']." ".$page; $page = $_SERVER[QUERY_STRING]; $ipbesucher = $_SERVER['REMOTE_ADDR']; $nachrichtanmich = "\n\n" . $kopf . " ".$plugin_tx['sblog']['mail_file']." \"".$page."\"\n\n" ."*******************************************************\n" // ." From: ".$kopf." ".$plugin_tx['sblog']['mail_file']." \"".$page."\"\n\n" ." Text: \n".$sbmessage."\n\n From IP: $ipbesucher \n\n" ."*******************************************************\n" .""; $webmaster=$plugin_cf['sblog']['emailNoticeTo']; $header ="FROM:CMSimple sBlog <$webmaster>\n"; $header .="X-Mailer :PHP/" . phpversion()."\n"; $header .="X-Sender-IP: " .$_SERVER['REMOTE_ADDR']. "\n"; $header .="Content-Type: text/plain"; mail ($webmaster, $kopf, $nachrichtanmich, $header); /////////////////////////////////////////////// } if (fputs($fp,$sbentry) == FALSE) $tvari.="
ERROR: Cannot write to file ($sbfile)"; fclose($fp); header('Location: '.$_SERVER['REQUEST_URI']);exit; } } if (file_exists ($sbfile)){$thistext=$plugin_tx['sblog']['txt_header'];} else {$thistext="";}; $tvari .= "

" . $thistext . "

\n"; // first DIV encompasses whole output with editor, closes at the bottom /////// OUTPUT 1 ///////////////////// if(preg_match("true",$plugin_cf['sblog']['chronological_order'])){ if(ini_get('allow_url_fopen') != 1){ $vartl = "\n"; } sb_commentOutput(); $tvari .= $vartl; $tvari .= "
"; // $tvari .= "

 

"; } ///////// End of OUTPUT 1 //////////////////////// $tvari .= "\n"; $tvari .= "\n"; $tvari .= "
".$plugin_tx['sblog']['txt_newentry'] . "
\n"; $tvari .= "
\n"; $tvari .= "

" . $plugin_tx['sblog']['txt_postcomment'] . "

\n"; if(preg_match("true",$plugin_cf['sblog']['simpleCaptcha'])){ $tvari.=$plugin_tx['sblog']['txt_simpleCaptcha']."*:".$sbrandom."

\n"; $tvari.="\n"; } $tvari .= $plugin_tx['sblog']['txt_name'] . "*:
" . "
\n"; if(preg_match("true",$plugin_cf['sblog']['email'])){ $tvari .= $plugin_tx['sblog']['txt_email'] . ":
" . "
\n";} if(preg_match("true",$plugin_cf['sblog']['website'])){ $tvari .= $plugin_tx['sblog']['txt_website'] . ":
" . " 
\n";} if(preg_match("true",$plugin_cf['sblog']['image'])){ $tvari .= $plugin_tx['sblog']['txt_image'] . ":
" . " 
(ex: www.site.com/images/image.jpg)
\n";} $tvari .= "
" . $plugin_tx['sblog']['txt_message'] . "*:
" . "
\n"; $tvari .= "" . $plugin_tx['sblog']['txt_required'] . "
 
\n"; $tvari .= "
  
\n"; $tvari .= "
\n"; $tvari .= "
\n"; // $tvari .= " 
\n"; /////// OUTPUT 2 ///////////////////// if(!preg_match("true",$plugin_cf['sblog']['chronological_order'])){ if(ini_get('allow_url_fopen') != 1){ $vartIE = "\n"; $tvari .= $vartIE; } sb_commentOutput(); $tvari .= $vartl; } ///////// End of OUTPUT 2 //////////////////////// $tvari .= "
\n"; // closing of first DIV return $tvari; } function sb_cleantext($rawcode){ // This will remove HTML tags, javascript sections // and white space. It will also convert some // common HTML entities to their text equivalent // Clever bits cut and pasted from php_manual_en.html#ref.pcre $search = array ("']*?>.*?'si", // Strip out javascript "'<[\/\!]*?[^<>]*?>'si", // Strip out HTML tags "'([\r\n])[\s]+'", // Strip out white space "'&(quot|#34);'i", // Replace HTML entities "'&(amp|#38);'i", "'&(lt|#60);'i", "'&(gt|#62);'i", "'&(nbsp|#160);'i", "'&(iexcl|#161);'i", "'&(cent|#162);'i", "'&(pound|#163);'i", "'&(copy|#169);'i", "'&#(\d+);'e"); // evaluate as php $replace = array ("", "", "\\1", "\"", "&", "<", ">", " ", chr(161), chr(162), chr(163), chr(169), "chr(\\1)"); $sb_cleantext = preg_replace($search, $replace, $rawcode); // delete ."cleaned" when tested return $sb_cleantext; }//end of sb_cleantext function sb_commentOutput() { GLOBAL $sbfile, $vartl, $imgpath, $plugin_cf, $plugin_tx, $newwidth, $newheight, $width, $height; if(is_file($sbfile)){ $fp = fopen($sbfile, "r"); while (!feof($fp)) { $line = fgets($fp, 4096); if(substr($line,0,2) != '##'){ list($sbname,$sbemail,$sbwebsite,$sbtime,$sbdate,$sbimage,$sbmessage,$sbipaddr) = split( ";", $line); $vartm = ""; if ($sbmessage != '') $vartm .= "
\n"; if ($sbmessage != '') $vartm .= "
\n"; if ($sbmessage != '') $vartm .= "\n"; if ($sbmessage != '') $vartm .= "\n"; if ($sbimage != ''){ makeImg($sbimage); if(ini_get("allow_url_fopen") == 1) { // if ($newwidth != "" || $newheight != ""){ if (preg_match("http://", $sbimage)){ $vartm .= "\n"; } else { $vartm .= "\n"; } } else { // in case allow_url_fopen = off --------------- if (preg_match("http://", $sbimage)){ $vartm .= "\n"; } else { $vartm .= "\n"; } } } if ($sbmessage != '') $vartm .= "\n"; if ($sbmessage != '') $vartm .= "\n"; if ($sbmessage != '') $vartm .= "
" . $sbname . " | \n"; if ($sbmessage != '') $vartm .= "" . $sbdate . " " . $plugin_tx['sblog']['to_time'] . " " . $sbtime . " | \n"; if ($sbemail != '') $vartm .= "\"" \n"; if ($sbwebsite != '') $vartm .= "\"" \n"; if ($sbmessage != '') $vartm .= "\""\n"; if ($sbmessage != '') $vartm .= "
\""
\""
\""
\""
" . $sbmessage . " 
\n"; if(preg_match("true",$plugin_cf['sblog']['chronological_order'])){ $vartl = $vartl . $vartm; } else { $vartl = $vartm . $vartl; } } // end of - if(substr($line,0,2) != '##') - } return $vartl; fclose($fp); } }//end of sb_commentOutput function makeImg($sbimage) { // resizing of images global $hmax, $wmax, $plugin_cf, $newwidth, $newheight, $width, $height; // max width and height, max new width and new height if (preg_match("http:",$sbimage)) { list($width, $height, $type, $attr) = getimagesize($sbimage); } else { list($width, $height, $type, $attr) = getimagesize("http://" . $sbimage); } $hmax = $plugin_cf['sblog']['max_height']; $wmax = $plugin_cf['sblog']['max_width']; $hscale = $height / $hmax; $wscale = $width / $wmax; if (($hscale > 1) || ($wscale > 1)) { $scale = ($hscale > $wscale)?$hscale:$wscale; } else { $scale = 1; } $newwidth = floor($width / $scale); $newheight= floor($height / $scale); if ($newwidth == "0") $newwidth = ""; if ($newheight == "0") $newheight = ""; return $newwidth; return $newheight; return $width; return $height; } ?> Coaching entreprise - Graphologue - Recrutement - Toulouse : ACOR - Connexion
 
Connexion

 
 

Connexion

Ce système est réservé aux utilisateurs autorisés!

 

 

Coaching entreprise - Graphologue - Recrutement - Toulouse : ACOR