將 xtc 或 twe 的 Smarty 版本升級
使用 xtc 或 twe 架設購物網站的人應該很多這兩套系統都是使用 Smarty 樣版引擎
想要更新其實很簡單
到 [url]http://www.smarty.net/[/url] 下載 Smarty 新的版本
解壓縮後將其中的 libs 目錄名稱改成 Smarty_x.x.x 後,複製到 includes/classes 目錄下
修改 Smarty_x.x.x/Smarty.class.php 將 config_dir 設定成[code]
var $config_dir = 'lang';
[/code]再來修改設定檔 includes/application_top.php 所引用的 Smarty 版本[code]
require (DIR_WS_CLASSES.'Smarty_x.x.x/Smarty.class.php');
[/code]將 x.x.x 對應到剛加入的 includes/classes/Smarty_x.x.x 版本路徑
然後檢查網頁是否正常作業以及 Log 有無錯誤訊息
後台也請修改 admin/includes/application_top.php[code]
require(DIR_FS_CATALOG.DIR_WS_CLASSES . 'Smarty_x.x.x/Smarty.class.php');[/code]這樣就完成 Smarty 的升級了 另外要注意的是某些加工過的 xtc 或 twe 的版本
可能有使用到 Smarty 的 plugins 的機制
就要將舊版的 Smarty_x.x.x/plugins/ 目錄中找一下
複製到新版後應該可以直接使用
頁:
[1]