網(LieHuo.Net)教程 PHPCMS的tpl文件中使用{get 標簽出錯,這樣結果是get標簽部分直接顯示出來了。但是html模板文件為什么能使用get標簽,tpl模板中就不能識別呢?
以下為引用的內容: <tr> <th><strong><?=$k?>:</strong></th> <td colspan="4"><?=$v?></td> </tr> <?php } } ?> <!--以下為get標簽,不能識別--> {get sql="SELECT name,bankname,applyfor FROM `phpcms_member_detail` where userid = $userid" return="c"}{/get} <tr> <th bgcolor="#d0f0ff" colspan=5><strong>----以下資料不能再修改(如需修改,請聯系管理員)----</strong></th> </tr> |
傻瓜解決方案:
將相應代碼copy到html模板文件中,更新模板緩存后,到datacache_template目錄下找到對應*.tpl.php文件,再到文件中找到對應get標簽轉換后在tpl文件中的代碼,復制粘貼到想要使用的tpl模板文件中~~