• 观点

    互联网+时代,说建站,谈运营与网络营销

    ecshop新增加文章频道页面,新增一个独立功能页面详细图解教程

    时间:2020-12-21

    用户不满足ECSHOP原始页面,于是想增加新一个页面,ECSHOP教程今天为大家详细解说一下ECSHOP新增加一个独立文章频道页面,以及新增一个独立功能页面详细图解教程方法


    1. 我们先在ecshop网站根目录找到index.php复制一份,改成ecshop.php 这个文件名称随便你命名,你可以命名比如ecshop.php也可以



    2.修改成功xin.php以后打开找到:

    if (!$smarty->is_cached('index.dwt', $cache_id))

    $smarty->display('index.dwt', $cache_id);


    修改成功:


    if (!$smarty->is_cached('xin.dwt', $cache_id))

    $smarty->display('xin.dwt', $cache_id);


    3.继续修改找到:


        /* 页面中的动态内容 */

        assign_dynamic('index');

    }


    修改成:


      assign_dynamic('xin');



    4.找文件夹admin\includes的lib_template.php这个文件

    找到:


        'index' => array(

            '/library/ur_here.lbi' => 0,

            '/library/search_form.lbi' => 0,

            '/library/member.lbi' => 0,

            '/library/new_articles.lbi' => 0,

            '/library/category_tree.lbi' => 0,

            '/library/top10.lbi' => 0,

            '/library/invoice_query.lbi' => 0,

            '/library/recommend_best.lbi' => 3,

            '/library/recommend_new.lbi' => 3,

            '/library/recommend_hot.lbi' => 3,

            '/library/recommend_promotion.lbi' => 4,

            '/library/group_buy.lbi' => 3,

            '/library/auction.lbi' => 3,

            '/library/brands.lbi' => 3,

            '/library/promotion_info.lbi' => 0,

            '/library/cart.lbi' => 0,

            '/library/order_query.lbi' => 0,

            '/library/email_list.lbi' => 0,

            '/library/vote_list.lbi' => 0

        ),

    复制上面这段,粘贴到他下一行,修改成:

        'xin' => array(

            '/library/ur_here.lbi' => 0,

            '/library/search_form.lbi' => 0,

            '/library/member.lbi' => 0,

            '/library/new_articles.lbi' => 0,

            '/library/category_tree.lbi' => 0,

            '/library/top10.lbi' => 0,

            '/library/invoice_query.lbi' => 0,

            '/library/recommend_best.lbi' => 3,

            '/library/recommend_new.lbi' => 3,

            '/library/recommend_hot.lbi' => 3,

            '/library/recommend_promotion.lbi' => 4,

            '/library/group_buy.lbi' => 3,

            '/library/auction.lbi' => 3,

            '/library/brands.lbi' => 3,

            '/library/promotion_info.lbi' => 0,

            '/library/cart.lbi' => 0,

            '/library/order_query.lbi' => 0,

            '/library/email_list.lbi' => 0,

            '/library/vote_list.lbi' => 0

        ),


    5. 打开文件夹languages\zh_cn\admin中的template.php文件:


    找到:

    $_LANG['template_files']['index'] = '首页模板';

    复制,然后粘贴下面一行,然后index改成xin

    $_LANG['template_files']['xin'] = '文章频道模板';



    6.打开模板文件目录:themes\default  注明:default 模板文件夹打开libs.xml文件找到:


      <file name="index.dwt">

        <region name="">

          <lib>cart</lib>

          <lib>category_tree</lib>

          <lib>top10</lib>

          <lib>promotion_info</lib>

          <lib>auction</lib>

          <lib>group_buy</lib>

          <lib>order_query</lib>

          <lib>invoice_query</lib>

          <lib>vote_list</lib>

          <lib>email_list</lib>

        </region>

        <region name="?"/>

        <region name="">

          <lib>recommend_best</lib>

          <lib>recommend_new</lib>

          <lib>recommend_hot</lib>

        </region>

      </file>

    复制这段到他下面,把index.dwt改成xin.dwt

      <file name="xin.dwt">

        <region name="">

          <lib>cart</lib>

          <lib>category_tree</lib>

          <lib>top10</lib>

          <lib>promotion_info</lib>

          <lib>auction</lib>

          <lib>group_buy</lib>

          <lib>order_query</lib>

          <lib>invoice_query</lib>

          <lib>vote_list</lib>

          <lib>email_list</lib>

        </region>

        <region name="?"/>

        <region name="">

          <lib>recommend_best</lib>

          <lib>recommend_new</lib>

          <lib>recommend_hot</lib>

        </region>

      </file>




    7.到了这步以后,新增加页面就完成了,前台页面就是xin.php比如www.ecshop119.com/xin.php


    后台:模板管理---设置模板----文章频道页面  就是刚才新增加功能页面

    0
    首页
    案例
    关于
    联系