Visit 127.0.0.1/smarty/test/test.php A blank there's nothing there
Chrome Console Report Server 500
But there's no such error in Chrome's stealth version.
Don't know what reason, little white help.
The test.php code is as follows
left_delimiter ="{";//左定界符 $smarty->right_delimiter="}"; $smarty->template_dir ="tpl";//视图模板存放地址 $smarty->compile_dir="template_c"; //模板编译后的存放目录 $smarty->cache_dir = "cache"; //缓存 $smarty->caching = true; $smarty->cache_lifetime = 120; //缓存时间 $smarty->assign("title","标题"); //变量,value $smarty->assign("content","内容"); $smarty->display("test.html"); //模板名称
Test.html placed in the TPL folder
{$title} {$content}
The ubuntut14.04 is used.
Reply content:
Visit 127.0.0.1/smarty/test/test.php A blank there's nothing there
Chrome Console Report Server 500
But there's no such error in Chrome's stealth version.
Don't know what reason, little white help.
The test.php code is as follows
left_delimiter ="{";//左定界符 $smarty->right_delimiter="}"; $smarty->template_dir ="tpl";//视图模板存放地址 $smarty->compile_dir="template_c"; //模板编译后的存放目录 $smarty->cache_dir = "cache"; //缓存 $smarty->caching = true; $smarty->cache_lifetime = 120; //缓存时间 $smarty->assign("title","标题"); //变量,value $smarty->assign("content","内容"); $smarty->display("test.html"); //模板名称
Test.html placed in the TPL folder
{$title} {$content}
The ubuntut14.04 is used.
ini_set("display_errors","On"); error_reporting(E_ALL &~ E_NOTICE)
PHP configuration file default settings do not display error, you can set the php.ini file directly
Modify display_errors = off to
Display_errors = On
Can.