background image

     $template = preg_replace("/"(http)?[w./:]+?[^"]+?&[^"]+?"/e", "transamp('')", 

$template);
     $template = preg_replace("/<script[^>]*?src="(.+?)"(.*?)>s*</script>/ise", 

"strips 教程 criptamp('1', '2')", $template);

        $template = "<?php if(!defined('in_site')) exit('access denied!'); 
checktplrefresh('$tplfile', ".time()."); ?>n$template";

        if(!$fp = @fopen($objfile, 'wb')) {

      exit("directory '$objdir' not found or have no access!");
     }

     flock($fp, lock_ex);
        fwrite($fp, $template);

        flock($fp, lock_un);
     fclose($fp);

    }

    function transamp($str) {
     $str = str_replace('&', '&amp;', $str);

     $str = str_replace('&amp;amp;', '&amp;', $str);
     $str = str_replace('"', '"', $str);

     return $str;
    }

    function stripscriptamp($s, $extra) {

     $extra = str_replace('"', '"', $extra);
     $s = str_replace('&amp;', '&', $s);

     return "<script src="$s" type="text/网页特效"$extra></script>";
    }

    ?>