Problem with compile_dir

From: Date: Fri, 30 May 2003 19:00:57 +0000
Subject: Problem with compile_dir
References: 1  Groups: php.smarty.general 
Request: Send a blank email to php-smarty-general+get-9616@lists.php.net to get a copy of this message
Hi, This is my first problem with smarty I can't handle with my self. I haven't start to read source of smarty yet, but if I don't solve this I'll have to do that:(( to try ton solve that on that way. Any way, here is my problem. Smarty just can't see my template_c directory in some cases. I am developing under Win 2K server, and using Apache-1.3.x and php-4.3.0 and Smarty-2.5.0. If I set up $smarty->compile_dir, that all compiled templates are saved under root directory of my partition, otherwise if I don't set it up in most cases, everything is OK. Here is my config file $basePath = "F:/Inetpub/wwwroot/cms/"; require_once ($basePath . "functions/various.inc"); define('SMARTY_DIR', $basePath); require_once (SMARTY_DIR . "Smarty.class.php"); $smarty = new Smarty; $smarty->compile_check = true; //$smarty->debugging = true; $smarty->debugging = false; $smarty->template_dir = $basePath . "templates/"; $smarty->compile_dir = $basePath . "template_c/"; $smarty->config_dir = $basePath . "configs/"; $smarty->cache_dir = $basePath . "cashe/"; My application is in F:/Inetpub/wwwroot/cms/ directory. If I don't set compile_c it is working OK unless php script is more than one directory deep. Like in F:/Inetpub/wwwroot/cms/content/main/ In that case, compiled templates are again directly under F: This is begining of var_dump($smarty) in case when compile is seted object(smarty)(55) { ["template_dir"]=> string(37) "F:/Inetpub/wwwroot/pellady/templates/" ["compile_dir"]=> string(38) "F:/Inetpub/wwwroot/pellady/template_c/" ["config_dir"]=> string(35) "F:/Inetpub/wwwroot/pellady/configs/" ["plugins_dir"]=> array(1) { [0]=> string(7) "plugins" } ["debugging"]=> bool(false) ["debug_tpl"]=> string(0) "" ["debugging_ctrl"]=> string(4) "NONE" ["compile_check"]=> bool(true) ["force_compile"]=> bool(false) ["caching"]=> int(0) ["cache_dir"]=> string(33) "F:/Inetpub/wwwroot/pellady/cashe/" The biggest mistery for me that I just copy these setings from my other Smarty project , and everything is working perfectly there. Thnx for any help Ilic Aleksandar

« previous php.smarty.general (#9616) next »