0) && stripos($r,$_SERVER["HTTP_HOST"])===false && stripos($r,$h)===false && stripos($r,str_replace("www.","",$h))===false) { $r="'".mysql_real_escape_string($r)."'"; } else { $r="NULL"; } executeSql(str_replace("\n","",sprintf("replace into iprocms_stats_log set `HTTP_HOST`='%s', `REQUEST_URI`='%s', `REMOTE_ADDR`='%s', `REMOTE_HOST`='%s', `HTTP_REFERER`=%s, `HTTP_USER_AGENT`='%s', `session`='%s', `dt`=now()", $h, @$_SERVER["REQUEST_URI"], @$_SERVER["REMOTE_ADDR"], gethostbyaddr(@$_SERVER["REMOTE_ADDR"]), $r, @$_SERVER["HTTP_USER_AGENT"], session_id() ))); } $meta_title=""; $meta_keywords=""; $meta_description=""; $replacements=array('

'=>'
','
'=>'
',''=>'', '

'=>'
'); global $contents; $contents=null; $contents_wrapper="%s"; $addToHead=array(); require "contents.php"; #--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- #meta $head = $dom_html->getHead(); if (DEBUG_MODE) $meta_title="LOCAL: $page, $template - ". $meta_title; $head->getElementsByTagName("title")->item(0)->nodeValue=_utf8_ent($meta_title); $meta_keywords_url = str_ireplace(array('/nl/','/','.html'), array('','-',''), $_SERVER['_URI']); $meta_keywords_url = str_ireplace(array(' ','/','.html'), array(',','-',''), $meta_description); $meta_keywords_url = explode('-',$meta_keywords_url); $meta_keywords_url = implode(',',$meta_keywords_url); $dom_html->appendElement($head,"meta","",array("name"=>"keywords","content"=>($meta_keywords?$meta_keywords:$meta_keywords_url))); $dom_html->appendElement($head,"meta","",array("name"=>"description","content"=>$meta_description)); //echo __FILE__.__LINE__.'
$meta_title='.htmlentities(print_r($meta_title,1)).'
'; //echo __FILE__.__LINE__.'
$meta_keywords='.htmlentities(print_r($meta_keywords,1)).'
'; //echo __FILE__.__LINE__.'
$meta_description='.htmlentities(print_r($meta_description,1)).'
'; /**/ #output $dom_html->getDocument()->normalize(); $html = (string)$dom_html; #ajax calls if (isset($_SERVER['HTTP_X_REQUESTED_WITH']) && ($_SERVER['HTTP_X_REQUESTED_WITH']=='XMLHttpRequest')) { $contents_wrapper='%s'; $html='[[[[content]]]]'; } if (preg_match_all('#\{setting:([^\}]+)\}#',$html,$matches,PREG_SET_ORDER)) foreach ($matches as $match) $html=str_replace($match[0],getIprocmsSetting($match[1]),$html); #invisible $invisible=""; $invisible=" "; $replacements[""]=$invisible.""; #addToHead $replacements['']=implode("\n",$addToHead)."\n"; $html = str_replace(array_keys($replacements),$replacements,$html); $html = str_ireplace('

','
',$html); if ($contents!==null) $html = str_replace("[[[[content]]]]",sprintf($contents_wrapper,$contents),$html); if (preg_match_all('#\{lang:([^\}]+)\}#',$html,$matches,PREG_SET_ORDER)) { $l=trim($site_prefix,'/'); $l=empty($l)?'nl':$l; if (!empty($l)) { $arr=array(); foreach (explode("\n",file_get_contents('lang/'.$l.'.txt')) as $line) if (strlen($line=trim($line))>0) { $e=explode('=',$line); if (count($e)>1) { $k=array_shift($e); $arr[$k]=implode('=',$e); } } foreach ($matches as $match) { $html=str_replace( $match[0], isset($arr[$match[1]])?$arr[$match[1]]:'{'.$match[1].'}', $html ); } } } #addToHead //$replacements['']=implode("\n",$addToHead)."\n"; //$html = str_replace(array_keys($replacements),$replacements,$html); #mail riddler $html = preg_replace_callback("#(]*href=['\"]mailto:[^<]*)#i",create_function( '$lucifer', 'return "";' ),$html); #form tokens form_token_add($html); /**/ #ipro link if (!DEBUG_MODE && file_exists($fn="php/inc/ipro_link.inc.php")) { require_once $fn; ipro_link($html); } else { $fn="php/inc/ipro_link.inc.php"; debug("{$fn} does not exist"); } /**/ #end //echo __FILE__.__LINE__.'
$html='.htmlentities(print_r($html,1)).'
';die; echo $html; //end