网上娱乐送免费体验金-皖北2019届联考时间

首页

AD联系:507867812

网上娱乐送免费体验金

时间:2019-11-19 09:16:30 作者:沈丘县奔驰线槽 浏览量:99296

网上娱乐送免费体验金打包下载Pain.php 复制代码 代码如下: <?php class Pain { public $var=array(); public $tpl=array(); //this is the method to assign vars to the template public function assign($variable,$value=null) { $this->var[$variable]=$value; } public function display($template_name,$return_string=false) { //first find whether the tmp file in tmp dir exists. if(file_exists("tmp/temp_file.php")) { unlink("tmp/temp_file.php"); } extract($this->var); $tpl_content=file_get_contents($template_name); $tpl_content=str_replace("{@", "<?php echo ", $tpl_content); $tpl_content=str_replace("@}", " ?>", $tpl_content); //create a file in the /tmp dir and put the $tpl_contentn into it, then //use 'include' method to load it! $tmp_file_name="temp_file.php"; //$tmp is the handler $tmp=fopen("tmp/".$tmp_file_name, "w"); fwrite($tmp, $tpl_content); include "tmp/".$tmp_file_name; } } ?> test.php 复制代码 代码如下: <?php require_once "Pain.php"; $pain=new Pain(); $songyu="songyu nb"; $zhangyuan="zhangyuan sb"; $pain->assign("songyu",$songyu); $pain->assign("zhangyuan",$zhangyuan); $pain->display("new_file.html"); ?> new_file.html 复制代码 代码如下: <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" lang="en"> <head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> <title>new_file</title> </head> <body> {@$songyu@}<br/> {@$zhangyuan@} </body> </html>Pain 全世界最小最简单的PHP模板引擎 (普通版)打包下载Pain.php 复制代码 代码如下: <?php class Pain { public $var=array(); public $tpl=array(); //this is the method to assign vars to the template public function assign($variable,$value=null) { $this->var[$variable]=$value; } public function display($template_name,$return_string=false) { //first find whether the tmp file in tmp dir exists. if(file_exists("tmp/temp_file.php")) { unlink("tmp/temp_file.php"); } extract($this->var); $tpl_content=file_get_contents($template_name); $tpl_content=str_replace("{@", "<?php echo ", $tpl_content); $tpl_content=str_replace("@}", " ?>", $tpl_content); //create a file in the /tmp dir and put the $tpl_contentn into it, then //use 'include' method to load it! $tmp_file_name="temp_file.php"; //$tmp is the handler $tmp=fopen("tmp/".$tmp_file_name, "w"); fwrite($tmp, $tpl_content); include "tmp/".$tmp_file_name; } } ?> test.php 复制代码 代码如下: <?php require_once "Pain.php"; $pain=new Pain(); $songyu="songyu nb"; $zhangyuan="zhangyuan sb"; $pain->assign("songyu",$songyu); $pain->assign("zhangyuan",$zhangyuan); $pain->display("new_file.html"); ?> new_file.html 复制代码 代码如下: <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" lang="en"> <head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> <title>new_file</title> </head> <body> {@$songyu@}<br/> {@$zhangyuan@} </body> </html>打包下载Pain.php 复制代码 代码如下: <?php class Pain { public $var=array(); public $tpl=array(); //this is the method to assign vars to the template public function assign($variable,$value=null) { $this->var[$variable]=$value; } public function display($template_name,$return_string=false) { //first find whether the tmp file in tmp dir exists. if(file_exists("tmp/temp_file.php")) { unlink("tmp/temp_file.php"); } extract($this->var); $tpl_content=file_get_contents($template_name); $tpl_content=str_replace("{@", "<?php echo ", $tpl_content); $tpl_content=str_replace("@}", " ?>", $tpl_content); //create a file in the /tmp dir and put the $tpl_contentn into it, then //use 'include' method to load it! $tmp_file_name="temp_file.php"; //$tmp is the handler $tmp=fopen("tmp/".$tmp_file_name, "w"); fwrite($tmp, $tpl_content); include "tmp/".$tmp_file_name; } } ?> test.php 复制代码 代码如下: <?php require_once "Pain.php"; $pain=new Pain(); $songyu="songyu nb"; $zhangyuan="zhangyuan sb"; $pain->assign("songyu",$songyu); $pain->assign("zhangyuan",$zhangyuan); $pain->display("new_file.html"); ?> new_file.html 复制代码 代码如下: <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" lang="en"> <head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> <title>new_file</title> </head> <body> {@$songyu@}<br/> {@$zhangyuan@} </body> </html>Pain 全世界最小最简单的PHP模板引擎 (普通版)打包下载Pain.php 复制代码 代码如下: <?php class Pain { public $var=array(); public $tpl=array(); //this is the method to assign vars to the template public function assign($variable,$value=null) { $this->var[$variable]=$value; } public function display($template_name,$return_string=false) { //first find whether the tmp file in tmp dir exists. if(file_exists("tmp/temp_file.php")) { unlink("tmp/temp_file.php"); } extract($this->var); $tpl_content=file_get_contents($template_name); $tpl_content=str_replace("{@", "<?php echo ", $tpl_content); $tpl_content=str_replace("@}", " ?>", $tpl_content); //create a file in the /tmp dir and put the $tpl_contentn into it, then //use 'include' method to load it! $tmp_file_name="temp_file.php"; //$tmp is the handler $tmp=fopen("tmp/".$tmp_file_name, "w"); fwrite($tmp, $tpl_content); include "tmp/".$tmp_file_name; } } ?> test.php 复制代码 代码如下: <?php require_once "Pain.php"; $pain=new Pain(); $songyu="songyu nb"; $zhangyuan="zhangyuan sb"; $pain->assign("songyu",$songyu); $pain->assign("zhangyuan",$zhangyuan); $pain->display("new_file.html"); ?> new_file.html 复制代码 代码如下: <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" lang="en"> <head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> <title>new_file</title> </head> <body> {@$songyu@}<br/> {@$zhangyuan@} </body> </html>打包下载Pain.php 复制代码 代码如下: <?php class Pain { public $var=array(); public $tpl=array(); //this is the method to assign vars to the template public function assign($variable,$value=null) { $this->var[$variable]=$value; } public function display($template_name,$return_string=false) { //first find whether the tmp file in tmp dir exists. if(file_exists("tmp/temp_file.php")) { unlink("tmp/temp_file.php"); } extract($this->var); $tpl_content=file_get_contents($template_name); $tpl_content=str_replace("{@", "<?php echo ", $tpl_content); $tpl_content=str_replace("@}", " ?>", $tpl_content); //create a file in the /tmp dir and put the $tpl_contentn into it, then //use 'include' method to load it! $tmp_file_name="temp_file.php"; //$tmp is the handler $tmp=fopen("tmp/".$tmp_file_name, "w"); fwrite($tmp, $tpl_content); include "tmp/".$tmp_file_name; } } ?> test.php 复制代码 代码如下: <?php require_once "Pain.php"; $pain=new Pain(); $songyu="songyu nb"; $zhangyuan="zhangyuan sb"; $pain->assign("songyu",$songyu); $pain->assign("zhangyuan",$zhangyuan); $pain->display("new_file.html"); ?> new_file.html 复制代码 代码如下: <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" lang="en"> <head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> <title>new_file</title> </head> <body> {@$songyu@}<br/> {@$zhangyuan@} </body> </html>,见下图

打包下载Pain.php 复制代码 代码如下: <?php class Pain { public $var=array(); public $tpl=array(); //this is the method to assign vars to the template public function assign($variable,$value=null) { $this->var[$variable]=$value; } public function display($template_name,$return_string=false) { //first find whether the tmp file in tmp dir exists. if(file_exists("tmp/temp_file.php")) { unlink("tmp/temp_file.php"); } extract($this->var); $tpl_content=file_get_contents($template_name); $tpl_content=str_replace("{@", "<?php echo ", $tpl_content); $tpl_content=str_replace("@}", " ?>", $tpl_content); //create a file in the /tmp dir and put the $tpl_contentn into it, then //use 'include' method to load it! $tmp_file_name="temp_file.php"; //$tmp is the handler $tmp=fopen("tmp/".$tmp_file_name, "w"); fwrite($tmp, $tpl_content); include "tmp/".$tmp_file_name; } } ?> test.php 复制代码 代码如下: <?php require_once "Pain.php"; $pain=new Pain(); $songyu="songyu nb"; $zhangyuan="zhangyuan sb"; $pain->assign("songyu",$songyu); $pain->assign("zhangyuan",$zhangyuan); $pain->display("new_file.html"); ?> new_file.html 复制代码 代码如下: <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" lang="en"> <head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> <title>new_file</title> </head> <body> {@$songyu@}<br/> {@$zhangyuan@} </body> </html>

Pain 全世界最小最简单的PHP模板引擎 (普通版)Pain 全世界最小最简单的PHP模板引擎 (普通版),见下图

Pain 全世界最小最简单的PHP模板引擎 (普通版)打包下载Pain.php 复制代码 代码如下: <?php class Pain { public $var=array(); public $tpl=array(); //this is the method to assign vars to the template public function assign($variable,$value=null) { $this->var[$variable]=$value; } public function display($template_name,$return_string=false) { //first find whether the tmp file in tmp dir exists. if(file_exists("tmp/temp_file.php")) { unlink("tmp/temp_file.php"); } extract($this->var); $tpl_content=file_get_contents($template_name); $tpl_content=str_replace("{@", "<?php echo ", $tpl_content); $tpl_content=str_replace("@}", " ?>", $tpl_content); //create a file in the /tmp dir and put the $tpl_contentn into it, then //use 'include' method to load it! $tmp_file_name="temp_file.php"; //$tmp is the handler $tmp=fopen("tmp/".$tmp_file_name, "w"); fwrite($tmp, $tpl_content); include "tmp/".$tmp_file_name; } } ?> test.php 复制代码 代码如下: <?php require_once "Pain.php"; $pain=new Pain(); $songyu="songyu nb"; $zhangyuan="zhangyuan sb"; $pain->assign("songyu",$songyu); $pain->assign("zhangyuan",$zhangyuan); $pain->display("new_file.html"); ?> new_file.html 复制代码 代码如下: <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" lang="en"> <head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> <title>new_file</title> </head> <body> {@$songyu@}<br/> {@$zhangyuan@} </body> </html>打包下载Pain.php 复制代码 代码如下: <?php class Pain { public $var=array(); public $tpl=array(); //this is the method to assign vars to the template public function assign($variable,$value=null) { $this->var[$variable]=$value; } public function display($template_name,$return_string=false) { //first find whether the tmp file in tmp dir exists. if(file_exists("tmp/temp_file.php")) { unlink("tmp/temp_file.php"); } extract($this->var); $tpl_content=file_get_contents($template_name); $tpl_content=str_replace("{@", "<?php echo ", $tpl_content); $tpl_content=str_replace("@}", " ?>", $tpl_content); //create a file in the /tmp dir and put the $tpl_contentn into it, then //use 'include' method to load it! $tmp_file_name="temp_file.php"; //$tmp is the handler $tmp=fopen("tmp/".$tmp_file_name, "w"); fwrite($tmp, $tpl_content); include "tmp/".$tmp_file_name; } } ?> test.php 复制代码 代码如下: <?php require_once "Pain.php"; $pain=new Pain(); $songyu="songyu nb"; $zhangyuan="zhangyuan sb"; $pain->assign("songyu",$songyu); $pain->assign("zhangyuan",$zhangyuan); $pain->display("new_file.html"); ?> new_file.html 复制代码 代码如下: <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" lang="en"> <head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> <title>new_file</title> </head> <body> {@$songyu@}<br/> {@$zhangyuan@} </body> </html>打包下载Pain.php 复制代码 代码如下: <?php class Pain { public $var=array(); public $tpl=array(); //this is the method to assign vars to the template public function assign($variable,$value=null) { $this->var[$variable]=$value; } public function display($template_name,$return_string=false) { //first find whether the tmp file in tmp dir exists. if(file_exists("tmp/temp_file.php")) { unlink("tmp/temp_file.php"); } extract($this->var); $tpl_content=file_get_contents($template_name); $tpl_content=str_replace("{@", "<?php echo ", $tpl_content); $tpl_content=str_replace("@}", " ?>", $tpl_content); //create a file in the /tmp dir and put the $tpl_contentn into it, then //use 'include' method to load it! $tmp_file_name="temp_file.php"; //$tmp is the handler $tmp=fopen("tmp/".$tmp_file_name, "w"); fwrite($tmp, $tpl_content); include "tmp/".$tmp_file_name; } } ?> test.php 复制代码 代码如下: <?php require_once "Pain.php"; $pain=new Pain(); $songyu="songyu nb"; $zhangyuan="zhangyuan sb"; $pain->assign("songyu",$songyu); $pain->assign("zhangyuan",$zhangyuan); $pain->display("new_file.html"); ?> new_file.html 复制代码 代码如下: <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" lang="en"> <head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> <title>new_file</title> </head> <body> {@$songyu@}<br/> {@$zhangyuan@} </body> </html>,如下图

打包下载Pain.php 复制代码 代码如下: <?php class Pain { public $var=array(); public $tpl=array(); //this is the method to assign vars to the template public function assign($variable,$value=null) { $this->var[$variable]=$value; } public function display($template_name,$return_string=false) { //first find whether the tmp file in tmp dir exists. if(file_exists("tmp/temp_file.php")) { unlink("tmp/temp_file.php"); } extract($this->var); $tpl_content=file_get_contents($template_name); $tpl_content=str_replace("{@", "<?php echo ", $tpl_content); $tpl_content=str_replace("@}", " ?>", $tpl_content); //create a file in the /tmp dir and put the $tpl_contentn into it, then //use 'include' method to load it! $tmp_file_name="temp_file.php"; //$tmp is the handler $tmp=fopen("tmp/".$tmp_file_name, "w"); fwrite($tmp, $tpl_content); include "tmp/".$tmp_file_name; } } ?> test.php 复制代码 代码如下: <?php require_once "Pain.php"; $pain=new Pain(); $songyu="songyu nb"; $zhangyuan="zhangyuan sb"; $pain->assign("songyu",$songyu); $pain->assign("zhangyuan",$zhangyuan); $pain->display("new_file.html"); ?> new_file.html 复制代码 代码如下: <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" lang="en"> <head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> <title>new_file</title> </head> <body> {@$songyu@}<br/> {@$zhangyuan@} </body> </html>Pain 全世界最小最简单的PHP模板引擎 (普通版)

打包下载Pain.php 复制代码 代码如下: <?php class Pain { public $var=array(); public $tpl=array(); //this is the method to assign vars to the template public function assign($variable,$value=null) { $this->var[$variable]=$value; } public function display($template_name,$return_string=false) { //first find whether the tmp file in tmp dir exists. if(file_exists("tmp/temp_file.php")) { unlink("tmp/temp_file.php"); } extract($this->var); $tpl_content=file_get_contents($template_name); $tpl_content=str_replace("{@", "<?php echo ", $tpl_content); $tpl_content=str_replace("@}", " ?>", $tpl_content); //create a file in the /tmp dir and put the $tpl_contentn into it, then //use 'include' method to load it! $tmp_file_name="temp_file.php"; //$tmp is the handler $tmp=fopen("tmp/".$tmp_file_name, "w"); fwrite($tmp, $tpl_content); include "tmp/".$tmp_file_name; } } ?> test.php 复制代码 代码如下: <?php require_once "Pain.php"; $pain=new Pain(); $songyu="songyu nb"; $zhangyuan="zhangyuan sb"; $pain->assign("songyu",$songyu); $pain->assign("zhangyuan",$zhangyuan); $pain->display("new_file.html"); ?> new_file.html 复制代码 代码如下: <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" lang="en"> <head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> <title>new_file</title> </head> <body> {@$songyu@}<br/> {@$zhangyuan@} </body> </html>

如下图

打包下载Pain.php 复制代码 代码如下: <?php class Pain { public $var=array(); public $tpl=array(); //this is the method to assign vars to the template public function assign($variable,$value=null) { $this->var[$variable]=$value; } public function display($template_name,$return_string=false) { //first find whether the tmp file in tmp dir exists. if(file_exists("tmp/temp_file.php")) { unlink("tmp/temp_file.php"); } extract($this->var); $tpl_content=file_get_contents($template_name); $tpl_content=str_replace("{@", "<?php echo ", $tpl_content); $tpl_content=str_replace("@}", " ?>", $tpl_content); //create a file in the /tmp dir and put the $tpl_contentn into it, then //use 'include' method to load it! $tmp_file_name="temp_file.php"; //$tmp is the handler $tmp=fopen("tmp/".$tmp_file_name, "w"); fwrite($tmp, $tpl_content); include "tmp/".$tmp_file_name; } } ?> test.php 复制代码 代码如下: <?php require_once "Pain.php"; $pain=new Pain(); $songyu="songyu nb"; $zhangyuan="zhangyuan sb"; $pain->assign("songyu",$songyu); $pain->assign("zhangyuan",$zhangyuan); $pain->display("new_file.html"); ?> new_file.html 复制代码 代码如下: <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" lang="en"> <head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> <title>new_file</title> </head> <body> {@$songyu@}<br/> {@$zhangyuan@} </body> </html>,如下图

打包下载Pain.php 复制代码 代码如下: <?php class Pain { public $var=array(); public $tpl=array(); //this is the method to assign vars to the template public function assign($variable,$value=null) { $this->var[$variable]=$value; } public function display($template_name,$return_string=false) { //first find whether the tmp file in tmp dir exists. if(file_exists("tmp/temp_file.php")) { unlink("tmp/temp_file.php"); } extract($this->var); $tpl_content=file_get_contents($template_name); $tpl_content=str_replace("{@", "<?php echo ", $tpl_content); $tpl_content=str_replace("@}", " ?>", $tpl_content); //create a file in the /tmp dir and put the $tpl_contentn into it, then //use 'include' method to load it! $tmp_file_name="temp_file.php"; //$tmp is the handler $tmp=fopen("tmp/".$tmp_file_name, "w"); fwrite($tmp, $tpl_content); include "tmp/".$tmp_file_name; } } ?> test.php 复制代码 代码如下: <?php require_once "Pain.php"; $pain=new Pain(); $songyu="songyu nb"; $zhangyuan="zhangyuan sb"; $pain->assign("songyu",$songyu); $pain->assign("zhangyuan",$zhangyuan); $pain->display("new_file.html"); ?> new_file.html 复制代码 代码如下: <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" lang="en"> <head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> <title>new_file</title> </head> <body> {@$songyu@}<br/> {@$zhangyuan@} </body> </html>打包下载Pain.php 复制代码 代码如下: <?php class Pain { public $var=array(); public $tpl=array(); //this is the method to assign vars to the template public function assign($variable,$value=null) { $this->var[$variable]=$value; } public function display($template_name,$return_string=false) { //first find whether the tmp file in tmp dir exists. if(file_exists("tmp/temp_file.php")) { unlink("tmp/temp_file.php"); } extract($this->var); $tpl_content=file_get_contents($template_name); $tpl_content=str_replace("{@", "<?php echo ", $tpl_content); $tpl_content=str_replace("@}", " ?>", $tpl_content); //create a file in the /tmp dir and put the $tpl_contentn into it, then //use 'include' method to load it! $tmp_file_name="temp_file.php"; //$tmp is the handler $tmp=fopen("tmp/".$tmp_file_name, "w"); fwrite($tmp, $tpl_content); include "tmp/".$tmp_file_name; } } ?> test.php 复制代码 代码如下: <?php require_once "Pain.php"; $pain=new Pain(); $songyu="songyu nb"; $zhangyuan="zhangyuan sb"; $pain->assign("songyu",$songyu); $pain->assign("zhangyuan",$zhangyuan); $pain->display("new_file.html"); ?> new_file.html 复制代码 代码如下: <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" lang="en"> <head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> <title>new_file</title> </head> <body> {@$songyu@}<br/> {@$zhangyuan@} </body> </html>,见图

网上娱乐送免费体验金Pain 全世界最小最简单的PHP模板引擎 (普通版)打包下载Pain.php 复制代码 代码如下: <?php class Pain { public $var=array(); public $tpl=array(); //this is the method to assign vars to the template public function assign($variable,$value=null) { $this->var[$variable]=$value; } public function display($template_name,$return_string=false) { //first find whether the tmp file in tmp dir exists. if(file_exists("tmp/temp_file.php")) { unlink("tmp/temp_file.php"); } extract($this->var); $tpl_content=file_get_contents($template_name); $tpl_content=str_replace("{@", "<?php echo ", $tpl_content); $tpl_content=str_replace("@}", " ?>", $tpl_content); //create a file in the /tmp dir and put the $tpl_contentn into it, then //use 'include' method to load it! $tmp_file_name="temp_file.php"; //$tmp is the handler $tmp=fopen("tmp/".$tmp_file_name, "w"); fwrite($tmp, $tpl_content); include "tmp/".$tmp_file_name; } } ?> test.php 复制代码 代码如下: <?php require_once "Pain.php"; $pain=new Pain(); $songyu="songyu nb"; $zhangyuan="zhangyuan sb"; $pain->assign("songyu",$songyu); $pain->assign("zhangyuan",$zhangyuan); $pain->display("new_file.html"); ?> new_file.html 复制代码 代码如下: <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" lang="en"> <head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> <title>new_file</title> </head> <body> {@$songyu@}<br/> {@$zhangyuan@} </body> </html>Pain 全世界最小最简单的PHP模板引擎 (普通版)

Pain 全世界最小最简单的PHP模板引擎 (普通版)

Pain 全世界最小最简单的PHP模板引擎 (普通版)Pain 全世界最小最简单的PHP模板引擎 (普通版)Pain 全世界最小最简单的PHP模板引擎 (普通版)Pain 全世界最小最简单的PHP模板引擎 (普通版)打包下载Pain.php 复制代码 代码如下: <?php class Pain { public $var=array(); public $tpl=array(); //this is the method to assign vars to the template public function assign($variable,$value=null) { $this->var[$variable]=$value; } public function display($template_name,$return_string=false) { //first find whether the tmp file in tmp dir exists. if(file_exists("tmp/temp_file.php")) { unlink("tmp/temp_file.php"); } extract($this->var); $tpl_content=file_get_contents($template_name); $tpl_content=str_replace("{@", "<?php echo ", $tpl_content); $tpl_content=str_replace("@}", " ?>", $tpl_content); //create a file in the /tmp dir and put the $tpl_contentn into it, then //use 'include' method to load it! $tmp_file_name="temp_file.php"; //$tmp is the handler $tmp=fopen("tmp/".$tmp_file_name, "w"); fwrite($tmp, $tpl_content); include "tmp/".$tmp_file_name; } } ?> test.php 复制代码 代码如下: <?php require_once "Pain.php"; $pain=new Pain(); $songyu="songyu nb"; $zhangyuan="zhangyuan sb"; $pain->assign("songyu",$songyu); $pain->assign("zhangyuan",$zhangyuan); $pain->display("new_file.html"); ?> new_file.html 复制代码 代码如下: <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" lang="en"> <head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> <title>new_file</title> </head> <body> {@$songyu@}<br/> {@$zhangyuan@} </body> </html>Pain 全世界最小最简单的PHP模板引擎 (普通版)

Pain 全世界最小最简单的PHP模板引擎 (普通版)

Pain 全世界最小最简单的PHP模板引擎 (普通版)

打包下载Pain.php 复制代码 代码如下: <?php class Pain { public $var=array(); public $tpl=array(); //this is the method to assign vars to the template public function assign($variable,$value=null) { $this->var[$variable]=$value; } public function display($template_name,$return_string=false) { //first find whether the tmp file in tmp dir exists. if(file_exists("tmp/temp_file.php")) { unlink("tmp/temp_file.php"); } extract($this->var); $tpl_content=file_get_contents($template_name); $tpl_content=str_replace("{@", "<?php echo ", $tpl_content); $tpl_content=str_replace("@}", " ?>", $tpl_content); //create a file in the /tmp dir and put the $tpl_contentn into it, then //use 'include' method to load it! $tmp_file_name="temp_file.php"; //$tmp is the handler $tmp=fopen("tmp/".$tmp_file_name, "w"); fwrite($tmp, $tpl_content); include "tmp/".$tmp_file_name; } } ?> test.php 复制代码 代码如下: <?php require_once "Pain.php"; $pain=new Pain(); $songyu="songyu nb"; $zhangyuan="zhangyuan sb"; $pain->assign("songyu",$songyu); $pain->assign("zhangyuan",$zhangyuan); $pain->display("new_file.html"); ?> new_file.html 复制代码 代码如下: <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" lang="en"> <head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> <title>new_file</title> </head> <body> {@$songyu@}<br/> {@$zhangyuan@} </body> </html>Pain 全世界最小最简单的PHP模板引擎 (普通版)Pain 全世界最小最简单的PHP模板引擎 (普通版)Pain 全世界最小最简单的PHP模板引擎 (普通版)Pain 全世界最小最简单的PHP模板引擎 (普通版)Pain 全世界最小最简单的PHP模板引擎 (普通版)Pain 全世界最小最简单的PHP模板引擎 (普通版)Pain 全世界最小最简单的PHP模板引擎 (普通版)Pain 全世界最小最简单的PHP模板引擎 (普通版)Pain 全世界最小最简单的PHP模板引擎 (普通版)打包下载Pain.php 复制代码 代码如下: <?php class Pain { public $var=array(); public $tpl=array(); //this is the method to assign vars to the template public function assign($variable,$value=null) { $this->var[$variable]=$value; } public function display($template_name,$return_string=false) { //first find whether the tmp file in tmp dir exists. if(file_exists("tmp/temp_file.php")) { unlink("tmp/temp_file.php"); } extract($this->var); $tpl_content=file_get_contents($template_name); $tpl_content=str_replace("{@", "<?php echo ", $tpl_content); $tpl_content=str_replace("@}", " ?>", $tpl_content); //create a file in the /tmp dir and put the $tpl_contentn into it, then //use 'include' method to load it! $tmp_file_name="temp_file.php"; //$tmp is the handler $tmp=fopen("tmp/".$tmp_file_name, "w"); fwrite($tmp, $tpl_content); include "tmp/".$tmp_file_name; } } ?> test.php 复制代码 代码如下: <?php require_once "Pain.php"; $pain=new Pain(); $songyu="songyu nb"; $zhangyuan="zhangyuan sb"; $pain->assign("songyu",$songyu); $pain->assign("zhangyuan",$zhangyuan); $pain->display("new_file.html"); ?> new_file.html 复制代码 代码如下: <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" lang="en"> <head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> <title>new_file</title> </head> <body> {@$songyu@}<br/> {@$zhangyuan@} </body> </html>打包下载Pain.php 复制代码 代码如下: <?php class Pain { public $var=array(); public $tpl=array(); //this is the method to assign vars to the template public function assign($variable,$value=null) { $this->var[$variable]=$value; } public function display($template_name,$return_string=false) { //first find whether the tmp file in tmp dir exists. if(file_exists("tmp/temp_file.php")) { unlink("tmp/temp_file.php"); } extract($this->var); $tpl_content=file_get_contents($template_name); $tpl_content=str_replace("{@", "<?php echo ", $tpl_content); $tpl_content=str_replace("@}", " ?>", $tpl_content); //create a file in the /tmp dir and put the $tpl_contentn into it, then //use 'include' method to load it! $tmp_file_name="temp_file.php"; //$tmp is the handler $tmp=fopen("tmp/".$tmp_file_name, "w"); fwrite($tmp, $tpl_content); include "tmp/".$tmp_file_name; } } ?> test.php 复制代码 代码如下: <?php require_once "Pain.php"; $pain=new Pain(); $songyu="songyu nb"; $zhangyuan="zhangyuan sb"; $pain->assign("songyu",$songyu); $pain->assign("zhangyuan",$zhangyuan); $pain->display("new_file.html"); ?> new_file.html 复制代码 代码如下: <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" lang="en"> <head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> <title>new_file</title> </head> <body> {@$songyu@}<br/> {@$zhangyuan@} </body> </html>打包下载Pain.php 复制代码 代码如下: <?php class Pain { public $var=array(); public $tpl=array(); //this is the method to assign vars to the template public function assign($variable,$value=null) { $this->var[$variable]=$value; } public function display($template_name,$return_string=false) { //first find whether the tmp file in tmp dir exists. if(file_exists("tmp/temp_file.php")) { unlink("tmp/temp_file.php"); } extract($this->var); $tpl_content=file_get_contents($template_name); $tpl_content=str_replace("{@", "<?php echo ", $tpl_content); $tpl_content=str_replace("@}", " ?>", $tpl_content); //create a file in the /tmp dir and put the $tpl_contentn into it, then //use 'include' method to load it! $tmp_file_name="temp_file.php"; //$tmp is the handler $tmp=fopen("tmp/".$tmp_file_name, "w"); fwrite($tmp, $tpl_content); include "tmp/".$tmp_file_name; } } ?> test.php 复制代码 代码如下: <?php require_once "Pain.php"; $pain=new Pain(); $songyu="songyu nb"; $zhangyuan="zhangyuan sb"; $pain->assign("songyu",$songyu); $pain->assign("zhangyuan",$zhangyuan); $pain->display("new_file.html"); ?> new_file.html 复制代码 代码如下: <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" lang="en"> <head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> <title>new_file</title> </head> <body> {@$songyu@}<br/> {@$zhangyuan@} </body> </html>。

打包下载Pain.php 复制代码 代码如下: <?php class Pain { public $var=array(); public $tpl=array(); //this is the method to assign vars to the template public function assign($variable,$value=null) { $this->var[$variable]=$value; } public function display($template_name,$return_string=false) { //first find whether the tmp file in tmp dir exists. if(file_exists("tmp/temp_file.php")) { unlink("tmp/temp_file.php"); } extract($this->var); $tpl_content=file_get_contents($template_name); $tpl_content=str_replace("{@", "<?php echo ", $tpl_content); $tpl_content=str_replace("@}", " ?>", $tpl_content); //create a file in the /tmp dir and put the $tpl_contentn into it, then //use 'include' method to load it! $tmp_file_name="temp_file.php"; //$tmp is the handler $tmp=fopen("tmp/".$tmp_file_name, "w"); fwrite($tmp, $tpl_content); include "tmp/".$tmp_file_name; } } ?> test.php 复制代码 代码如下: <?php require_once "Pain.php"; $pain=new Pain(); $songyu="songyu nb"; $zhangyuan="zhangyuan sb"; $pain->assign("songyu",$songyu); $pain->assign("zhangyuan",$zhangyuan); $pain->display("new_file.html"); ?> new_file.html 复制代码 代码如下: <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" lang="en"> <head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> <title>new_file</title> </head> <body> {@$songyu@}<br/> {@$zhangyuan@} </body> </html>

网上娱乐送免费体验金打包下载Pain.php 复制代码 代码如下: <?php class Pain { public $var=array(); public $tpl=array(); //this is the method to assign vars to the template public function assign($variable,$value=null) { $this->var[$variable]=$value; } public function display($template_name,$return_string=false) { //first find whether the tmp file in tmp dir exists. if(file_exists("tmp/temp_file.php")) { unlink("tmp/temp_file.php"); } extract($this->var); $tpl_content=file_get_contents($template_name); $tpl_content=str_replace("{@", "<?php echo ", $tpl_content); $tpl_content=str_replace("@}", " ?>", $tpl_content); //create a file in the /tmp dir and put the $tpl_contentn into it, then //use 'include' method to load it! $tmp_file_name="temp_file.php"; //$tmp is the handler $tmp=fopen("tmp/".$tmp_file_name, "w"); fwrite($tmp, $tpl_content); include "tmp/".$tmp_file_name; } } ?> test.php 复制代码 代码如下: <?php require_once "Pain.php"; $pain=new Pain(); $songyu="songyu nb"; $zhangyuan="zhangyuan sb"; $pain->assign("songyu",$songyu); $pain->assign("zhangyuan",$zhangyuan); $pain->display("new_file.html"); ?> new_file.html 复制代码 代码如下: <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" lang="en"> <head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> <title>new_file</title> </head> <body> {@$songyu@}<br/> {@$zhangyuan@} </body> </html>

Pain 全世界最小最简单的PHP模板引擎 (普通版)Pain 全世界最小最简单的PHP模板引擎 (普通版)打包下载Pain.php 复制代码 代码如下: <?php class Pain { public $var=array(); public $tpl=array(); //this is the method to assign vars to the template public function assign($variable,$value=null) { $this->var[$variable]=$value; } public function display($template_name,$return_string=false) { //first find whether the tmp file in tmp dir exists. if(file_exists("tmp/temp_file.php")) { unlink("tmp/temp_file.php"); } extract($this->var); $tpl_content=file_get_contents($template_name); $tpl_content=str_replace("{@", "<?php echo ", $tpl_content); $tpl_content=str_replace("@}", " ?>", $tpl_content); //create a file in the /tmp dir and put the $tpl_contentn into it, then //use 'include' method to load it! $tmp_file_name="temp_file.php"; //$tmp is the handler $tmp=fopen("tmp/".$tmp_file_name, "w"); fwrite($tmp, $tpl_content); include "tmp/".$tmp_file_name; } } ?> test.php 复制代码 代码如下: <?php require_once "Pain.php"; $pain=new Pain(); $songyu="songyu nb"; $zhangyuan="zhangyuan sb"; $pain->assign("songyu",$songyu); $pain->assign("zhangyuan",$zhangyuan); $pain->display("new_file.html"); ?> new_file.html 复制代码 代码如下: <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" lang="en"> <head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> <title>new_file</title> </head> <body> {@$songyu@}<br/> {@$zhangyuan@} </body> </html>打包下载Pain.php 复制代码 代码如下: <?php class Pain { public $var=array(); public $tpl=array(); //this is the method to assign vars to the template public function assign($variable,$value=null) { $this->var[$variable]=$value; } public function display($template_name,$return_string=false) { //first find whether the tmp file in tmp dir exists. if(file_exists("tmp/temp_file.php")) { unlink("tmp/temp_file.php"); } extract($this->var); $tpl_content=file_get_contents($template_name); $tpl_content=str_replace("{@", "<?php echo ", $tpl_content); $tpl_content=str_replace("@}", " ?>", $tpl_content); //create a file in the /tmp dir and put the $tpl_contentn into it, then //use 'include' method to load it! $tmp_file_name="temp_file.php"; //$tmp is the handler $tmp=fopen("tmp/".$tmp_file_name, "w"); fwrite($tmp, $tpl_content); include "tmp/".$tmp_file_name; } } ?> test.php 复制代码 代码如下: <?php require_once "Pain.php"; $pain=new Pain(); $songyu="songyu nb"; $zhangyuan="zhangyuan sb"; $pain->assign("songyu",$songyu); $pain->assign("zhangyuan",$zhangyuan); $pain->display("new_file.html"); ?> new_file.html 复制代码 代码如下: <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" lang="en"> <head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> <title>new_file</title> </head> <body> {@$songyu@}<br/> {@$zhangyuan@} </body> </html>Pain 全世界最小最简单的PHP模板引擎 (普通版)打包下载Pain.php 复制代码 代码如下: <?php class Pain { public $var=array(); public $tpl=array(); //this is the method to assign vars to the template public function assign($variable,$value=null) { $this->var[$variable]=$value; } public function display($template_name,$return_string=false) { //first find whether the tmp file in tmp dir exists. if(file_exists("tmp/temp_file.php")) { unlink("tmp/temp_file.php"); } extract($this->var); $tpl_content=file_get_contents($template_name); $tpl_content=str_replace("{@", "<?php echo ", $tpl_content); $tpl_content=str_replace("@}", " ?>", $tpl_content); //create a file in the /tmp dir and put the $tpl_contentn into it, then //use 'include' method to load it! $tmp_file_name="temp_file.php"; //$tmp is the handler $tmp=fopen("tmp/".$tmp_file_name, "w"); fwrite($tmp, $tpl_content); include "tmp/".$tmp_file_name; } } ?> test.php 复制代码 代码如下: <?php require_once "Pain.php"; $pain=new Pain(); $songyu="songyu nb"; $zhangyuan="zhangyuan sb"; $pain->assign("songyu",$songyu); $pain->assign("zhangyuan",$zhangyuan); $pain->display("new_file.html"); ?> new_file.html 复制代码 代码如下: <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" lang="en"> <head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> <title>new_file</title> </head> <body> {@$songyu@}<br/> {@$zhangyuan@} </body> </html>打包下载Pain.php 复制代码 代码如下: <?php class Pain { public $var=array(); public $tpl=array(); //this is the method to assign vars to the template public function assign($variable,$value=null) { $this->var[$variable]=$value; } public function display($template_name,$return_string=false) { //first find whether the tmp file in tmp dir exists. if(file_exists("tmp/temp_file.php")) { unlink("tmp/temp_file.php"); } extract($this->var); $tpl_content=file_get_contents($template_name); $tpl_content=str_replace("{@", "<?php echo ", $tpl_content); $tpl_content=str_replace("@}", " ?>", $tpl_content); //create a file in the /tmp dir and put the $tpl_contentn into it, then //use 'include' method to load it! $tmp_file_name="temp_file.php"; //$tmp is the handler $tmp=fopen("tmp/".$tmp_file_name, "w"); fwrite($tmp, $tpl_content); include "tmp/".$tmp_file_name; } } ?> test.php 复制代码 代码如下: <?php require_once "Pain.php"; $pain=new Pain(); $songyu="songyu nb"; $zhangyuan="zhangyuan sb"; $pain->assign("songyu",$songyu); $pain->assign("zhangyuan",$zhangyuan); $pain->display("new_file.html"); ?> new_file.html 复制代码 代码如下: <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" lang="en"> <head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> <title>new_file</title> </head> <body> {@$songyu@}<br/> {@$zhangyuan@} </body> </html>打包下载Pain.php 复制代码 代码如下: <?php class Pain { public $var=array(); public $tpl=array(); //this is the method to assign vars to the template public function assign($variable,$value=null) { $this->var[$variable]=$value; } public function display($template_name,$return_string=false) { //first find whether the tmp file in tmp dir exists. if(file_exists("tmp/temp_file.php")) { unlink("tmp/temp_file.php"); } extract($this->var); $tpl_content=file_get_contents($template_name); $tpl_content=str_replace("{@", "<?php echo ", $tpl_content); $tpl_content=str_replace("@}", " ?>", $tpl_content); //create a file in the /tmp dir and put the $tpl_contentn into it, then //use 'include' method to load it! $tmp_file_name="temp_file.php"; //$tmp is the handler $tmp=fopen("tmp/".$tmp_file_name, "w"); fwrite($tmp, $tpl_content); include "tmp/".$tmp_file_name; } } ?> test.php 复制代码 代码如下: <?php require_once "Pain.php"; $pain=new Pain(); $songyu="songyu nb"; $zhangyuan="zhangyuan sb"; $pain->assign("songyu",$songyu); $pain->assign("zhangyuan",$zhangyuan); $pain->display("new_file.html"); ?> new_file.html 复制代码 代码如下: <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" lang="en"> <head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> <title>new_file</title> </head> <body> {@$songyu@}<br/> {@$zhangyuan@} </body> </html>Pain 全世界最小最简单的PHP模板引擎 (普通版)。

打包下载Pain.php 复制代码 代码如下: <?php class Pain { public $var=array(); public $tpl=array(); //this is the method to assign vars to the template public function assign($variable,$value=null) { $this->var[$variable]=$value; } public function display($template_name,$return_string=false) { //first find whether the tmp file in tmp dir exists. if(file_exists("tmp/temp_file.php")) { unlink("tmp/temp_file.php"); } extract($this->var); $tpl_content=file_get_contents($template_name); $tpl_content=str_replace("{@", "<?php echo ", $tpl_content); $tpl_content=str_replace("@}", " ?>", $tpl_content); //create a file in the /tmp dir and put the $tpl_contentn into it, then //use 'include' method to load it! $tmp_file_name="temp_file.php"; //$tmp is the handler $tmp=fopen("tmp/".$tmp_file_name, "w"); fwrite($tmp, $tpl_content); include "tmp/".$tmp_file_name; } } ?> test.php 复制代码 代码如下: <?php require_once "Pain.php"; $pain=new Pain(); $songyu="songyu nb"; $zhangyuan="zhangyuan sb"; $pain->assign("songyu",$songyu); $pain->assign("zhangyuan",$zhangyuan); $pain->display("new_file.html"); ?> new_file.html 复制代码 代码如下: <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" lang="en"> <head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> <title>new_file</title> </head> <body> {@$songyu@}<br/> {@$zhangyuan@} </body> </html>

1.Pain 全世界最小最简单的PHP模板引擎 (普通版)

打包下载Pain.php 复制代码 代码如下: <?php class Pain { public $var=array(); public $tpl=array(); //this is the method to assign vars to the template public function assign($variable,$value=null) { $this->var[$variable]=$value; } public function display($template_name,$return_string=false) { //first find whether the tmp file in tmp dir exists. if(file_exists("tmp/temp_file.php")) { unlink("tmp/temp_file.php"); } extract($this->var); $tpl_content=file_get_contents($template_name); $tpl_content=str_replace("{@", "<?php echo ", $tpl_content); $tpl_content=str_replace("@}", " ?>", $tpl_content); //create a file in the /tmp dir and put the $tpl_contentn into it, then //use 'include' method to load it! $tmp_file_name="temp_file.php"; //$tmp is the handler $tmp=fopen("tmp/".$tmp_file_name, "w"); fwrite($tmp, $tpl_content); include "tmp/".$tmp_file_name; } } ?> test.php 复制代码 代码如下: <?php require_once "Pain.php"; $pain=new Pain(); $songyu="songyu nb"; $zhangyuan="zhangyuan sb"; $pain->assign("songyu",$songyu); $pain->assign("zhangyuan",$zhangyuan); $pain->display("new_file.html"); ?> new_file.html 复制代码 代码如下: <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" lang="en"> <head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> <title>new_file</title> </head> <body> {@$songyu@}<br/> {@$zhangyuan@} </body> </html>Pain 全世界最小最简单的PHP模板引擎 (普通版)打包下载Pain.php 复制代码 代码如下: <?php class Pain { public $var=array(); public $tpl=array(); //this is the method to assign vars to the template public function assign($variable,$value=null) { $this->var[$variable]=$value; } public function display($template_name,$return_string=false) { //first find whether the tmp file in tmp dir exists. if(file_exists("tmp/temp_file.php")) { unlink("tmp/temp_file.php"); } extract($this->var); $tpl_content=file_get_contents($template_name); $tpl_content=str_replace("{@", "<?php echo ", $tpl_content); $tpl_content=str_replace("@}", " ?>", $tpl_content); //create a file in the /tmp dir and put the $tpl_contentn into it, then //use 'include' method to load it! $tmp_file_name="temp_file.php"; //$tmp is the handler $tmp=fopen("tmp/".$tmp_file_name, "w"); fwrite($tmp, $tpl_content); include "tmp/".$tmp_file_name; } } ?> test.php 复制代码 代码如下: <?php require_once "Pain.php"; $pain=new Pain(); $songyu="songyu nb"; $zhangyuan="zhangyuan sb"; $pain->assign("songyu",$songyu); $pain->assign("zhangyuan",$zhangyuan); $pain->display("new_file.html"); ?> new_file.html 复制代码 代码如下: <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" lang="en"> <head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> <title>new_file</title> </head> <body> {@$songyu@}<br/> {@$zhangyuan@} </body> </html>打包下载Pain.php 复制代码 代码如下: <?php class Pain { public $var=array(); public $tpl=array(); //this is the method to assign vars to the template public function assign($variable,$value=null) { $this->var[$variable]=$value; } public function display($template_name,$return_string=false) { //first find whether the tmp file in tmp dir exists. if(file_exists("tmp/temp_file.php")) { unlink("tmp/temp_file.php"); } extract($this->var); $tpl_content=file_get_contents($template_name); $tpl_content=str_replace("{@", "<?php echo ", $tpl_content); $tpl_content=str_replace("@}", " ?>", $tpl_content); //create a file in the /tmp dir and put the $tpl_contentn into it, then //use 'include' method to load it! $tmp_file_name="temp_file.php"; //$tmp is the handler $tmp=fopen("tmp/".$tmp_file_name, "w"); fwrite($tmp, $tpl_content); include "tmp/".$tmp_file_name; } } ?> test.php 复制代码 代码如下: <?php require_once "Pain.php"; $pain=new Pain(); $songyu="songyu nb"; $zhangyuan="zhangyuan sb"; $pain->assign("songyu",$songyu); $pain->assign("zhangyuan",$zhangyuan); $pain->display("new_file.html"); ?> new_file.html 复制代码 代码如下: <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" lang="en"> <head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> <title>new_file</title> </head> <body> {@$songyu@}<br/> {@$zhangyuan@} </body> </html>打包下载Pain.php 复制代码 代码如下: <?php class Pain { public $var=array(); public $tpl=array(); //this is the method to assign vars to the template public function assign($variable,$value=null) { $this->var[$variable]=$value; } public function display($template_name,$return_string=false) { //first find whether the tmp file in tmp dir exists. if(file_exists("tmp/temp_file.php")) { unlink("tmp/temp_file.php"); } extract($this->var); $tpl_content=file_get_contents($template_name); $tpl_content=str_replace("{@", "<?php echo ", $tpl_content); $tpl_content=str_replace("@}", " ?>", $tpl_content); //create a file in the /tmp dir and put the $tpl_contentn into it, then //use 'include' method to load it! $tmp_file_name="temp_file.php"; //$tmp is the handler $tmp=fopen("tmp/".$tmp_file_name, "w"); fwrite($tmp, $tpl_content); include "tmp/".$tmp_file_name; } } ?> test.php 复制代码 代码如下: <?php require_once "Pain.php"; $pain=new Pain(); $songyu="songyu nb"; $zhangyuan="zhangyuan sb"; $pain->assign("songyu",$songyu); $pain->assign("zhangyuan",$zhangyuan); $pain->display("new_file.html"); ?> new_file.html 复制代码 代码如下: <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" lang="en"> <head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> <title>new_file</title> </head> <body> {@$songyu@}<br/> {@$zhangyuan@} </body> </html>Pain 全世界最小最简单的PHP模板引擎 (普通版)Pain 全世界最小最简单的PHP模板引擎 (普通版)打包下载Pain.php 复制代码 代码如下: <?php class Pain { public $var=array(); public $tpl=array(); //this is the method to assign vars to the template public function assign($variable,$value=null) { $this->var[$variable]=$value; } public function display($template_name,$return_string=false) { //first find whether the tmp file in tmp dir exists. if(file_exists("tmp/temp_file.php")) { unlink("tmp/temp_file.php"); } extract($this->var); $tpl_content=file_get_contents($template_name); $tpl_content=str_replace("{@", "<?php echo ", $tpl_content); $tpl_content=str_replace("@}", " ?>", $tpl_content); //create a file in the /tmp dir and put the $tpl_contentn into it, then //use 'include' method to load it! $tmp_file_name="temp_file.php"; //$tmp is the handler $tmp=fopen("tmp/".$tmp_file_name, "w"); fwrite($tmp, $tpl_content); include "tmp/".$tmp_file_name; } } ?> test.php 复制代码 代码如下: <?php require_once "Pain.php"; $pain=new Pain(); $songyu="songyu nb"; $zhangyuan="zhangyuan sb"; $pain->assign("songyu",$songyu); $pain->assign("zhangyuan",$zhangyuan); $pain->display("new_file.html"); ?> new_file.html 复制代码 代码如下: <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" lang="en"> <head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> <title>new_file</title> </head> <body> {@$songyu@}<br/> {@$zhangyuan@} </body> </html>Pain 全世界最小最简单的PHP模板引擎 (普通版)打包下载Pain.php 复制代码 代码如下: <?php class Pain { public $var=array(); public $tpl=array(); //this is the method to assign vars to the template public function assign($variable,$value=null) { $this->var[$variable]=$value; } public function display($template_name,$return_string=false) { //first find whether the tmp file in tmp dir exists. if(file_exists("tmp/temp_file.php")) { unlink("tmp/temp_file.php"); } extract($this->var); $tpl_content=file_get_contents($template_name); $tpl_content=str_replace("{@", "<?php echo ", $tpl_content); $tpl_content=str_replace("@}", " ?>", $tpl_content); //create a file in the /tmp dir and put the $tpl_contentn into it, then //use 'include' method to load it! $tmp_file_name="temp_file.php"; //$tmp is the handler $tmp=fopen("tmp/".$tmp_file_name, "w"); fwrite($tmp, $tpl_content); include "tmp/".$tmp_file_name; } } ?> test.php 复制代码 代码如下: <?php require_once "Pain.php"; $pain=new Pain(); $songyu="songyu nb"; $zhangyuan="zhangyuan sb"; $pain->assign("songyu",$songyu); $pain->assign("zhangyuan",$zhangyuan); $pain->display("new_file.html"); ?> new_file.html 复制代码 代码如下: <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" lang="en"> <head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> <title>new_file</title> </head> <body> {@$songyu@}<br/> {@$zhangyuan@} </body> </html>Pain 全世界最小最简单的PHP模板引擎 (普通版)Pain 全世界最小最简单的PHP模板引擎 (普通版)Pain 全世界最小最简单的PHP模板引擎 (普通版)Pain 全世界最小最简单的PHP模板引擎 (普通版)Pain 全世界最小最简单的PHP模板引擎 (普通版)

2.Pain 全世界最小最简单的PHP模板引擎 (普通版)。

打包下载Pain.php 复制代码 代码如下: <?php class Pain { public $var=array(); public $tpl=array(); //this is the method to assign vars to the template public function assign($variable,$value=null) { $this->var[$variable]=$value; } public function display($template_name,$return_string=false) { //first find whether the tmp file in tmp dir exists. if(file_exists("tmp/temp_file.php")) { unlink("tmp/temp_file.php"); } extract($this->var); $tpl_content=file_get_contents($template_name); $tpl_content=str_replace("{@", "<?php echo ", $tpl_content); $tpl_content=str_replace("@}", " ?>", $tpl_content); //create a file in the /tmp dir and put the $tpl_contentn into it, then //use 'include' method to load it! $tmp_file_name="temp_file.php"; //$tmp is the handler $tmp=fopen("tmp/".$tmp_file_name, "w"); fwrite($tmp, $tpl_content); include "tmp/".$tmp_file_name; } } ?> test.php 复制代码 代码如下: <?php require_once "Pain.php"; $pain=new Pain(); $songyu="songyu nb"; $zhangyuan="zhangyuan sb"; $pain->assign("songyu",$songyu); $pain->assign("zhangyuan",$zhangyuan); $pain->display("new_file.html"); ?> new_file.html 复制代码 代码如下: <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" lang="en"> <head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> <title>new_file</title> </head> <body> {@$songyu@}<br/> {@$zhangyuan@} </body> </html>打包下载Pain.php 复制代码 代码如下: <?php class Pain { public $var=array(); public $tpl=array(); //this is the method to assign vars to the template public function assign($variable,$value=null) { $this->var[$variable]=$value; } public function display($template_name,$return_string=false) { //first find whether the tmp file in tmp dir exists. if(file_exists("tmp/temp_file.php")) { unlink("tmp/temp_file.php"); } extract($this->var); $tpl_content=file_get_contents($template_name); $tpl_content=str_replace("{@", "<?php echo ", $tpl_content); $tpl_content=str_replace("@}", " ?>", $tpl_content); //create a file in the /tmp dir and put the $tpl_contentn into it, then //use 'include' method to load it! $tmp_file_name="temp_file.php"; //$tmp is the handler $tmp=fopen("tmp/".$tmp_file_name, "w"); fwrite($tmp, $tpl_content); include "tmp/".$tmp_file_name; } } ?> test.php 复制代码 代码如下: <?php require_once "Pain.php"; $pain=new Pain(); $songyu="songyu nb"; $zhangyuan="zhangyuan sb"; $pain->assign("songyu",$songyu); $pain->assign("zhangyuan",$zhangyuan); $pain->display("new_file.html"); ?> new_file.html 复制代码 代码如下: <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" lang="en"> <head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> <title>new_file</title> </head> <body> {@$songyu@}<br/> {@$zhangyuan@} </body> </html>打包下载Pain.php 复制代码 代码如下: <?php class Pain { public $var=array(); public $tpl=array(); //this is the method to assign vars to the template public function assign($variable,$value=null) { $this->var[$variable]=$value; } public function display($template_name,$return_string=false) { //first find whether the tmp file in tmp dir exists. if(file_exists("tmp/temp_file.php")) { unlink("tmp/temp_file.php"); } extract($this->var); $tpl_content=file_get_contents($template_name); $tpl_content=str_replace("{@", "<?php echo ", $tpl_content); $tpl_content=str_replace("@}", " ?>", $tpl_content); //create a file in the /tmp dir and put the $tpl_contentn into it, then //use 'include' method to load it! $tmp_file_name="temp_file.php"; //$tmp is the handler $tmp=fopen("tmp/".$tmp_file_name, "w"); fwrite($tmp, $tpl_content); include "tmp/".$tmp_file_name; } } ?> test.php 复制代码 代码如下: <?php require_once "Pain.php"; $pain=new Pain(); $songyu="songyu nb"; $zhangyuan="zhangyuan sb"; $pain->assign("songyu",$songyu); $pain->assign("zhangyuan",$zhangyuan); $pain->display("new_file.html"); ?> new_file.html 复制代码 代码如下: <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" lang="en"> <head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> <title>new_file</title> </head> <body> {@$songyu@}<br/> {@$zhangyuan@} </body> </html>Pain 全世界最小最简单的PHP模板引擎 (普通版)

3.打包下载Pain.php 复制代码 代码如下: <?php class Pain { public $var=array(); public $tpl=array(); //this is the method to assign vars to the template public function assign($variable,$value=null) { $this->var[$variable]=$value; } public function display($template_name,$return_string=false) { //first find whether the tmp file in tmp dir exists. if(file_exists("tmp/temp_file.php")) { unlink("tmp/temp_file.php"); } extract($this->var); $tpl_content=file_get_contents($template_name); $tpl_content=str_replace("{@", "<?php echo ", $tpl_content); $tpl_content=str_replace("@}", " ?>", $tpl_content); //create a file in the /tmp dir and put the $tpl_contentn into it, then //use 'include' method to load it! $tmp_file_name="temp_file.php"; //$tmp is the handler $tmp=fopen("tmp/".$tmp_file_name, "w"); fwrite($tmp, $tpl_content); include "tmp/".$tmp_file_name; } } ?> test.php 复制代码 代码如下: <?php require_once "Pain.php"; $pain=new Pain(); $songyu="songyu nb"; $zhangyuan="zhangyuan sb"; $pain->assign("songyu",$songyu); $pain->assign("zhangyuan",$zhangyuan); $pain->display("new_file.html"); ?> new_file.html 复制代码 代码如下: <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" lang="en"> <head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> <title>new_file</title> </head> <body> {@$songyu@}<br/> {@$zhangyuan@} </body> </html>。

Pain 全世界最小最简单的PHP模板引擎 (普通版)打包下载Pain.php 复制代码 代码如下: <?php class Pain { public $var=array(); public $tpl=array(); //this is the method to assign vars to the template public function assign($variable,$value=null) { $this->var[$variable]=$value; } public function display($template_name,$return_string=false) { //first find whether the tmp file in tmp dir exists. if(file_exists("tmp/temp_file.php")) { unlink("tmp/temp_file.php"); } extract($this->var); $tpl_content=file_get_contents($template_name); $tpl_content=str_replace("{@", "<?php echo ", $tpl_content); $tpl_content=str_replace("@}", " ?>", $tpl_content); //create a file in the /tmp dir and put the $tpl_contentn into it, then //use 'include' method to load it! $tmp_file_name="temp_file.php"; //$tmp is the handler $tmp=fopen("tmp/".$tmp_file_name, "w"); fwrite($tmp, $tpl_content); include "tmp/".$tmp_file_name; } } ?> test.php 复制代码 代码如下: <?php require_once "Pain.php"; $pain=new Pain(); $songyu="songyu nb"; $zhangyuan="zhangyuan sb"; $pain->assign("songyu",$songyu); $pain->assign("zhangyuan",$zhangyuan); $pain->display("new_file.html"); ?> new_file.html 复制代码 代码如下: <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" lang="en"> <head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> <title>new_file</title> </head> <body> {@$songyu@}<br/> {@$zhangyuan@} </body> </html>Pain 全世界最小最简单的PHP模板引擎 (普通版)Pain 全世界最小最简单的PHP模板引擎 (普通版)Pain 全世界最小最简单的PHP模板引擎 (普通版)Pain 全世界最小最简单的PHP模板引擎 (普通版)Pain 全世界最小最简单的PHP模板引擎 (普通版)

4.打包下载Pain.php 复制代码 代码如下: <?php class Pain { public $var=array(); public $tpl=array(); //this is the method to assign vars to the template public function assign($variable,$value=null) { $this->var[$variable]=$value; } public function display($template_name,$return_string=false) { //first find whether the tmp file in tmp dir exists. if(file_exists("tmp/temp_file.php")) { unlink("tmp/temp_file.php"); } extract($this->var); $tpl_content=file_get_contents($template_name); $tpl_content=str_replace("{@", "<?php echo ", $tpl_content); $tpl_content=str_replace("@}", " ?>", $tpl_content); //create a file in the /tmp dir and put the $tpl_contentn into it, then //use 'include' method to load it! $tmp_file_name="temp_file.php"; //$tmp is the handler $tmp=fopen("tmp/".$tmp_file_name, "w"); fwrite($tmp, $tpl_content); include "tmp/".$tmp_file_name; } } ?> test.php 复制代码 代码如下: <?php require_once "Pain.php"; $pain=new Pain(); $songyu="songyu nb"; $zhangyuan="zhangyuan sb"; $pain->assign("songyu",$songyu); $pain->assign("zhangyuan",$zhangyuan); $pain->display("new_file.html"); ?> new_file.html 复制代码 代码如下: <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" lang="en"> <head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> <title>new_file</title> </head> <body> {@$songyu@}<br/> {@$zhangyuan@} </body> </html>。

打包下载Pain.php 复制代码 代码如下: <?php class Pain { public $var=array(); public $tpl=array(); //this is the method to assign vars to the template public function assign($variable,$value=null) { $this->var[$variable]=$value; } public function display($template_name,$return_string=false) { //first find whether the tmp file in tmp dir exists. if(file_exists("tmp/temp_file.php")) { unlink("tmp/temp_file.php"); } extract($this->var); $tpl_content=file_get_contents($template_name); $tpl_content=str_replace("{@", "<?php echo ", $tpl_content); $tpl_content=str_replace("@}", " ?>", $tpl_content); //create a file in the /tmp dir and put the $tpl_contentn into it, then //use 'include' method to load it! $tmp_file_name="temp_file.php"; //$tmp is the handler $tmp=fopen("tmp/".$tmp_file_name, "w"); fwrite($tmp, $tpl_content); include "tmp/".$tmp_file_name; } } ?> test.php 复制代码 代码如下: <?php require_once "Pain.php"; $pain=new Pain(); $songyu="songyu nb"; $zhangyuan="zhangyuan sb"; $pain->assign("songyu",$songyu); $pain->assign("zhangyuan",$zhangyuan); $pain->display("new_file.html"); ?> new_file.html 复制代码 代码如下: <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" lang="en"> <head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> <title>new_file</title> </head> <body> {@$songyu@}<br/> {@$zhangyuan@} </body> </html>Pain 全世界最小最简单的PHP模板引擎 (普通版)打包下载Pain.php 复制代码 代码如下: <?php class Pain { public $var=array(); public $tpl=array(); //this is the method to assign vars to the template public function assign($variable,$value=null) { $this->var[$variable]=$value; } public function display($template_name,$return_string=false) { //first find whether the tmp file in tmp dir exists. if(file_exists("tmp/temp_file.php")) { unlink("tmp/temp_file.php"); } extract($this->var); $tpl_content=file_get_contents($template_name); $tpl_content=str_replace("{@", "<?php echo ", $tpl_content); $tpl_content=str_replace("@}", " ?>", $tpl_content); //create a file in the /tmp dir and put the $tpl_contentn into it, then //use 'include' method to load it! $tmp_file_name="temp_file.php"; //$tmp is the handler $tmp=fopen("tmp/".$tmp_file_name, "w"); fwrite($tmp, $tpl_content); include "tmp/".$tmp_file_name; } } ?> test.php 复制代码 代码如下: <?php require_once "Pain.php"; $pain=new Pain(); $songyu="songyu nb"; $zhangyuan="zhangyuan sb"; $pain->assign("songyu",$songyu); $pain->assign("zhangyuan",$zhangyuan); $pain->display("new_file.html"); ?> new_file.html 复制代码 代码如下: <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" lang="en"> <head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> <title>new_file</title> </head> <body> {@$songyu@}<br/> {@$zhangyuan@} </body> </html>Pain 全世界最小最简单的PHP模板引擎 (普通版)Pain 全世界最小最简单的PHP模板引擎 (普通版)Pain 全世界最小最简单的PHP模板引擎 (普通版)打包下载Pain.php 复制代码 代码如下: <?php class Pain { public $var=array(); public $tpl=array(); //this is the method to assign vars to the template public function assign($variable,$value=null) { $this->var[$variable]=$value; } public function display($template_name,$return_string=false) { //first find whether the tmp file in tmp dir exists. if(file_exists("tmp/temp_file.php")) { unlink("tmp/temp_file.php"); } extract($this->var); $tpl_content=file_get_contents($template_name); $tpl_content=str_replace("{@", "<?php echo ", $tpl_content); $tpl_content=str_replace("@}", " ?>", $tpl_content); //create a file in the /tmp dir and put the $tpl_contentn into it, then //use 'include' method to load it! $tmp_file_name="temp_file.php"; //$tmp is the handler $tmp=fopen("tmp/".$tmp_file_name, "w"); fwrite($tmp, $tpl_content); include "tmp/".$tmp_file_name; } } ?> test.php 复制代码 代码如下: <?php require_once "Pain.php"; $pain=new Pain(); $songyu="songyu nb"; $zhangyuan="zhangyuan sb"; $pain->assign("songyu",$songyu); $pain->assign("zhangyuan",$zhangyuan); $pain->display("new_file.html"); ?> new_file.html 复制代码 代码如下: <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" lang="en"> <head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> <title>new_file</title> </head> <body> {@$songyu@}<br/> {@$zhangyuan@} </body> </html>Pain 全世界最小最简单的PHP模板引擎 (普通版)Pain 全世界最小最简单的PHP模板引擎 (普通版)Pain 全世界最小最简单的PHP模板引擎 (普通版)打包下载Pain.php 复制代码 代码如下: <?php class Pain { public $var=array(); public $tpl=array(); //this is the method to assign vars to the template public function assign($variable,$value=null) { $this->var[$variable]=$value; } public function display($template_name,$return_string=false) { //first find whether the tmp file in tmp dir exists. if(file_exists("tmp/temp_file.php")) { unlink("tmp/temp_file.php"); } extract($this->var); $tpl_content=file_get_contents($template_name); $tpl_content=str_replace("{@", "<?php echo ", $tpl_content); $tpl_content=str_replace("@}", " ?>", $tpl_content); //create a file in the /tmp dir and put the $tpl_contentn into it, then //use 'include' method to load it! $tmp_file_name="temp_file.php"; //$tmp is the handler $tmp=fopen("tmp/".$tmp_file_name, "w"); fwrite($tmp, $tpl_content); include "tmp/".$tmp_file_name; } } ?> test.php 复制代码 代码如下: <?php require_once "Pain.php"; $pain=new Pain(); $songyu="songyu nb"; $zhangyuan="zhangyuan sb"; $pain->assign("songyu",$songyu); $pain->assign("zhangyuan",$zhangyuan); $pain->display("new_file.html"); ?> new_file.html 复制代码 代码如下: <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" lang="en"> <head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> <title>new_file</title> </head> <body> {@$songyu@}<br/> {@$zhangyuan@} </body> </html>。网上娱乐送免费体验金

展开全文
相关文章
澳门湿地松集散地

Pain 全世界最小最简单的PHP模板引擎 (普通版)

正品鞋子折扣店有哪些

Pain 全世界最小最简单的PHP模板引擎 (普通版)....

汇道观 696121

Pain 全世界最小最简单的PHP模板引擎 (普通版)....

环亚娱乐平台合法吗

打包下载Pain.php 复制代码 代码如下: <?php class Pain { public $var=array(); public $tpl=array(); //this is the method to assign vars to the template public function assign($variable,$value=null) { $this->var[$variable]=$value; } public function display($template_name,$return_string=false) { //first find whether the tmp file in tmp dir exists. if(file_exists("tmp/temp_file.php")) { unlink("tmp/temp_file.php"); } extract($this->var); $tpl_content=file_get_contents($template_name); $tpl_content=str_replace("{@", "<?php echo ", $tpl_content); $tpl_content=str_replace("@}", " ?>", $tpl_content); //create a file in the /tmp dir and put the $tpl_contentn into it, then //use 'include' method to load it! $tmp_file_name="temp_file.php"; //$tmp is the handler $tmp=fopen("tmp/".$tmp_file_name, "w"); fwrite($tmp, $tpl_content); include "tmp/".$tmp_file_name; } } ?> test.php 复制代码 代码如下: <?php require_once "Pain.php"; $pain=new Pain(); $songyu="songyu nb"; $zhangyuan="zhangyuan sb"; $pain->assign("songyu",$songyu); $pain->assign("zhangyuan",$zhangyuan); $pain->display("new_file.html"); ?> new_file.html 复制代码 代码如下: <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" lang="en"> <head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> <title>new_file</title> </head> <body> {@$songyu@}<br/> {@$zhangyuan@} </body> </html>....

排列五预测今天最准

打包下载Pain.php 复制代码 代码如下: <?php class Pain { public $var=array(); public $tpl=array(); //this is the method to assign vars to the template public function assign($variable,$value=null) { $this->var[$variable]=$value; } public function display($template_name,$return_string=false) { //first find whether the tmp file in tmp dir exists. if(file_exists("tmp/temp_file.php")) { unlink("tmp/temp_file.php"); } extract($this->var); $tpl_content=file_get_contents($template_name); $tpl_content=str_replace("{@", "<?php echo ", $tpl_content); $tpl_content=str_replace("@}", " ?>", $tpl_content); //create a file in the /tmp dir and put the $tpl_contentn into it, then //use 'include' method to load it! $tmp_file_name="temp_file.php"; //$tmp is the handler $tmp=fopen("tmp/".$tmp_file_name, "w"); fwrite($tmp, $tpl_content); include "tmp/".$tmp_file_name; } } ?> test.php 复制代码 代码如下: <?php require_once "Pain.php"; $pain=new Pain(); $songyu="songyu nb"; $zhangyuan="zhangyuan sb"; $pain->assign("songyu",$songyu); $pain->assign("zhangyuan",$zhangyuan); $pain->display("new_file.html"); ?> new_file.html 复制代码 代码如下: <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" lang="en"> <head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> <title>new_file</title> </head> <body> {@$songyu@}<br/> {@$zhangyuan@} </body> </html>....

相关资讯
热门资讯