When the smarty file contains dynamic content, an error is reported (http500). The edited phper2000 at 2012-06-1513: 31: 05 directly opens www. test. commenuindex can be used to obtain the list content. When smarty is used, & lt; {include & nbsp; file $ baseurlmenu smarty reports an error when include file contains dynamic content (http 500)
This post was last edited by phper2000 at 13:31:05
Directly open www.test.com/menu/indexand you will be able to get the desired content.
When doing smarty: <{include file = "$ baseurl/menu/index"}>
Index. php on the home page contains _ head. php, and _ head. php contains the above section. access: www.test.com/index won't work;
Of course, replace <{include file = "$ baseurl/menu/index"}> In _ head. php with the internal content obtained by www.test.com/menu/index!
How can I modify it?
------ Solution --------------------
Error reported
------ Solution --------------------
Smarty is just a template technology. after being interpreted by the template engine, it is a mixed html + php file. so to put it simply, your $ baseurl will be a url after being interpreted by the engine, while in php, if you use a url dynamically, you need to enable the allowed_url function (I cannot remember the name)
------ Solution --------------------
Only passing by zencart, not smarty