我们都知道织梦前台模板调用头部和尾部标签是{dede:include filename="*.htm"/} ,但是用到会员中心模板就无效,今天我们介绍一个方法来完成会员模板调用前台模板。
1:打开 /include/extend.func.php 在文件的最下面加入一个方法:
05 | * @param string $path 模板路径 |
08 | if (!function_exists( 'pasterTempletDiy' )) |
10 | function pasterTempletDiy($path) |
12 | require_once(DEDEINC. "/arc.partview.class.php" ); |
13 | global $cfg_basedir,$cfg_templets_dir,$cfg_df_style; |
14 | $tmpfile = $cfg_basedir.$cfg_templets_dir. '/' .$cfg_df_style. '/' .$path; |
15 | $dtp = new PartView(); |
16 | $dtp->SetTemplet($tmpfile); |
|
2:在织梦会员模板其他页面引入默认模板的头部尾部 的标签写法
2 | pasterTempletDiy( "head.htm" ); |
|
发表评论
评论列表(0条)