急smarty 上传到空间 配置文件需要怎样配置?该如何处理

WBOY
Freigeben: 2016-06-13 13:35:05
Original
642 Leute haben es durchsucht

急:smarty 上传到空间 配置文件需要怎样配置?
我的配置文件是这样写的
空间显示页面在 
wwwroot(主页文件夹) ccc date 2个文件夹
按这个配置放到 wwwroot 里 不能输出正常显示页面 而且也不提示错误信息..
我不放在这个文件夹放在 ccc 应该要怎样修改配置

PHP code
<!--

Code highlighting produced by Actipro CodeHighlighter (freeware)
http://www.CodeHighlighter.com/

-->
<?php include_once("class/Smarty.class.php");

 //******************
   $smarty = new smarty();
   $smarty->debugging=false;
   $smarty->compile_check=false;
   $smarty->template_dir = "./templates/".$smartytpl;
   $smarty->compile_dir = "./templates_c/";
   $smarty->config_dir = "./config/";
   $smarty->cache_dir = "./cache/";
   $smarty->caching = false;            //上传要 true
   $smarty->cache_lifetime = 118;
   $smarty->left_delimiter = "{";
   $smarty->right_delimiter = "}";
 //******************
?>

Nach dem Login kopieren


------解决方案--------------------
PHP code

 include_once("class/Smarty.class.php");
$global['path']['root']     = dirname(__FILE__) . '/';   //网站根目录
$smarty = new Smarty();
$smarty->template_dir         = $global['path']['root'] . 'templates/default/';  //smarty缓存文件存放的目录,我这边是 themes/default/
$smarty->compile_dir          = $global['path']['root'] . 'tmp/templates_c/';
$smarty->config_dir           = $global['path']['root'] . 'conf/';
$smarty->cache_dir            = $global['path']['cache']. 'smarty/';
$smarty->caching              = 0;
$smarty->cache_lifetime       = 6000;
$smarty->left_delimiter       = '<!--{';
$smarty->right_delimiter      = '}-->';
$smarty->trusted_dir          = $global['path']['root']; <div class="clear">
                 
              
              
        
            </div>
Nach dem Login kopieren
Verwandte Etiketten:
Quelle:php.cn
Erklärung dieser Website
Der Inhalt dieses Artikels wird freiwillig von Internetnutzern beigesteuert und das Urheberrecht liegt beim ursprünglichen Autor. Diese Website übernimmt keine entsprechende rechtliche Verantwortung. Wenn Sie Inhalte finden, bei denen der Verdacht eines Plagiats oder einer Rechtsverletzung besteht, wenden Sie sich bitte an admin@php.cn
Beliebte Tutorials
Mehr>
Neueste Downloads
Mehr>
Web-Effekte
Quellcode der Website
Website-Materialien
Frontend-Vorlage
Über uns Haftungsausschluss Sitemap
Chinesische PHP-Website:Online-PHP-Schulung für das Gemeinwohl,Helfen Sie PHP-Lernenden, sich schnell weiterzuentwickeln!