include_once "../../tadtools/language/{$xoopsConfig['language']}/admin_common.php"; define("_TAD_NEED_TADTOOLS","Need modules/tadtools. You can download tadtools from Tad's web."); include_once "../../tadtools/language/{$xoopsConfig['language']}/admin_common.php"; define("_TAD_NEED_TADTOOLS"," 需要 tadtools 模組,可至Tad教材網下載。"); ``` ### 二、移除多餘語系
include_once XOOPS_ROOT_PATH."/modules/tadtools/language/{$xoopsConfig['language']}/modinfo_common.php"; ``` ### 四、修改menu.php ``` $adminmenu = array(); $icon_dir=substr(XOOPS_VERSION,6,3)=='2.6'?"":"images/"; $i = 1; $adminmenu[$i]['title'] = _MI_TAD_ADMIN_HOME ; $adminmenu[$i]['link'] = 'admin/index.php' ; $adminmenu[$i]['desc'] = _MI_TAD_ADMIN_HOME_DESC ; $adminmenu[$i]['icon'] = 'images/admin/home.png' ; $i++; $adminmenu[$i]['title'] = _MI_TADXXX_ADMENU1; $adminmenu[$i]['link'] = "admin/main.php"; $adminmenu[$i]['desc'] = _MI_TADXXX_ADMENU1_DESC ; $adminmenu[$i]['icon'] = "images/admin/folder_txt.png"; $i++; $adminmenu[$i]['title'] = _MI_TAD_ADMIN_ABOUT; $adminmenu[$i]['link'] = 'admin/about.php'; $adminmenu[$i]['desc'] = _MI_TAD_ADMIN_ABOUT_DESC; $adminmenu[$i]['icon'] = 'images/admin/about.png'; ``` 1. 換掉圖示 [http://findicons.com](http://findicons.com/) 2. 根據menu.php新增或修改台樣板檔 五、修改後台樣板檔 ``` ``` 六、修改mainfile.php ================
$adminmenu = array(); $icon_dir=substr(XOOPS_VERSION,6,3)=='2.6'?"":"images/"; $i = 1; $adminmenu[$i]['title'] = _MI_TAD_ADMIN_HOME ; $adminmenu[$i]['link'] = 'admin/index.php' ; $adminmenu[$i]['desc'] = _MI_TAD_ADMIN_HOME_DESC ; $adminmenu[$i]['icon'] = 'images/admin/home.png' ; $i++; $adminmenu[$i]['title'] = _MI_TADXXX_ADMENU1; $adminmenu[$i]['link'] = "admin/main.php"; $adminmenu[$i]['desc'] = _MI_TADXXX_ADMENU1_DESC ; $adminmenu[$i]['icon'] = "images/admin/folder_txt.png"; $i++; $adminmenu[$i]['title'] = _MI_TAD_ADMIN_ABOUT; $adminmenu[$i]['link'] = 'admin/about.php'; $adminmenu[$i]['desc'] = _MI_TAD_ADMIN_ABOUT_DESC; $adminmenu[$i]['icon'] = 'images/admin/about.png'; ``` 1. 換掉圖示 [http://findicons.com](http://findicons.com/) 2. 根據menu.php新增或修改台樣板檔 五、修改後台樣板檔 ``` ``` 六、修改mainfile.php ================
``` 六、修改mainfile.php ================
include_once "../../mainfile.php"; include_once "function.php"; //判斷是否對該模組有管理權限 $isAdmin=false; if ($xoopsUser) { $module_id = $xoopsModule->getVar('mid'); $isAdmin=$xoopsUser->isAdmin($module_id); } $interface_menu[_TAD_TO_MOD]="index.php"; if($isAdmin){ $interface_menu[_TAD_TO_ADMIN]="admin/main.php"; } ``` ### 八、修改function.php ``` //引入TadTools的函式庫 if(!file_exists(XOOPS_ROOT_PATH."/modules/tadtools/tad_function.php")){ redirect_header("http://www.tad0616.net/modules/tad_uploader/index.php?of_cat_sn=50",3, _TAD_NEED_TADTOOLS); } include_once XOOPS_ROOT_PATH."/modules/tadtools/tad_function.php"; ``` ### 九、修改後台 1. 修改admin/main.php ``` /*-----------引入檔案區--------------*/ $xoopsOption['template_main'] = "tg_adm_main_tpl.html"; include_once "header.php"; include_once "../function.php"; include_once 'footer.php'; ?> ``` 2. 修改後台樣板檔 十、修改前台 ====== 1. 修改index.php ``` /*-----------引入檔案區--------------*/ include "header.php"; $xoopsOption['template_main'] = "tg_list_tpl.html"; include_once XOOPS_ROOT_PATH."/header.php"; include_once XOOPS_ROOT_PATH.'/footer.php'; ``` 2. 修改前台樣板檔 ``` <{$bootstrap}> <{$jquery}> <{$toolbar}> ``` 3. 常用樣板標籤 ``` $xoopsTpl->assign( "toolbar" , toolbar_bootstrap($interface_menu)) ; $xoopsTpl->assign( "bootstrap" , get_bootstrap()) ; $xoopsTpl->assign( "jquery" , get_jquery(true)) ; $xoopsTpl->assign( "isAdmin" , $isAdmin) ; <{$smarty.const._常數}> <{foreach item=xxx from=$ooo}> <{/foreach}> 分欄位 <{assign var="i" value=0}> <{assign var="total" value=1}> <{foreach item=class from=$data}> <{if $i==0}> <{/if}> 內容 <{assign var="i" value=$i+1}> <{assign var="total" value=$total+1}> <{if $i == 4 || $total==$count}> <{assign var="i" value=0}> <{/if}> <{/foreach}> ``` 4. 十一、常用bootstrap ================================================================================================= ``` 版型 區塊 表格
//引入TadTools的函式庫 if(!file_exists(XOOPS_ROOT_PATH."/modules/tadtools/tad_function.php")){ redirect_header("http://www.tad0616.net/modules/tad_uploader/index.php?of_cat_sn=50",3, _TAD_NEED_TADTOOLS); } include_once XOOPS_ROOT_PATH."/modules/tadtools/tad_function.php"; ``` ### 九、修改後台 1. 修改admin/main.php ``` /*-----------引入檔案區--------------*/ $xoopsOption['template_main'] = "tg_adm_main_tpl.html"; include_once "header.php"; include_once "../function.php"; include_once 'footer.php'; ?> ``` 2. 修改後台樣板檔 十、修改前台 ====== 1. 修改index.php ``` /*-----------引入檔案區--------------*/ include "header.php"; $xoopsOption['template_main'] = "tg_list_tpl.html"; include_once XOOPS_ROOT_PATH."/header.php"; include_once XOOPS_ROOT_PATH.'/footer.php'; ``` 2. 修改前台樣板檔 ``` <{$bootstrap}> <{$jquery}> <{$toolbar}> ``` 3. 常用樣板標籤 ``` $xoopsTpl->assign( "toolbar" , toolbar_bootstrap($interface_menu)) ; $xoopsTpl->assign( "bootstrap" , get_bootstrap()) ; $xoopsTpl->assign( "jquery" , get_jquery(true)) ; $xoopsTpl->assign( "isAdmin" , $isAdmin) ; <{$smarty.const._常數}> <{foreach item=xxx from=$ooo}> <{/foreach}> 分欄位 <{assign var="i" value=0}> <{assign var="total" value=1}> <{foreach item=class from=$data}> <{if $i==0}> <{/if}> 內容 <{assign var="i" value=$i+1}> <{assign var="total" value=$total+1}> <{if $i == 4 || $total==$count}> <{assign var="i" value=0}> <{/if}> <{/foreach}> ``` 4. 十一、常用bootstrap ================================================================================================= ``` 版型 區塊 表格
/*-----------引入檔案區--------------*/ $xoopsOption['template_main'] = "tg_adm_main_tpl.html"; include_once "header.php"; include_once "../function.php"; include_once 'footer.php'; ?> ``` 2. 修改後台樣板檔 十、修改前台 ====== 1. 修改index.php ``` /*-----------引入檔案區--------------*/ include "header.php"; $xoopsOption['template_main'] = "tg_list_tpl.html"; include_once XOOPS_ROOT_PATH."/header.php"; include_once XOOPS_ROOT_PATH.'/footer.php'; ``` 2. 修改前台樣板檔 ``` <{$bootstrap}> <{$jquery}> <{$toolbar}> ``` 3. 常用樣板標籤 ``` $xoopsTpl->assign( "toolbar" , toolbar_bootstrap($interface_menu)) ; $xoopsTpl->assign( "bootstrap" , get_bootstrap()) ; $xoopsTpl->assign( "jquery" , get_jquery(true)) ; $xoopsTpl->assign( "isAdmin" , $isAdmin) ; <{$smarty.const._常數}> <{foreach item=xxx from=$ooo}> <{/foreach}> 分欄位 <{assign var="i" value=0}> <{assign var="total" value=1}> <{foreach item=class from=$data}> <{if $i==0}> <{/if}> 內容 <{assign var="i" value=$i+1}> <{assign var="total" value=$total+1}> <{if $i == 4 || $total==$count}> <{assign var="i" value=0}> <{/if}> <{/foreach}> ``` 4. 十一、常用bootstrap ================================================================================================= ``` 版型 區塊 表格
/*-----------引入檔案區--------------*/ include "header.php"; $xoopsOption['template_main'] = "tg_list_tpl.html"; include_once XOOPS_ROOT_PATH."/header.php"; include_once XOOPS_ROOT_PATH.'/footer.php'; ``` 2. 修改前台樣板檔 ``` <{$bootstrap}> <{$jquery}> <{$toolbar}> ``` 3. 常用樣板標籤 ``` $xoopsTpl->assign( "toolbar" , toolbar_bootstrap($interface_menu)) ; $xoopsTpl->assign( "bootstrap" , get_bootstrap()) ; $xoopsTpl->assign( "jquery" , get_jquery(true)) ; $xoopsTpl->assign( "isAdmin" , $isAdmin) ; <{$smarty.const._常數}> <{foreach item=xxx from=$ooo}> <{/foreach}> 分欄位 <{assign var="i" value=0}> <{assign var="total" value=1}> <{foreach item=class from=$data}> <{if $i==0}> <{/if}> 內容 <{assign var="i" value=$i+1}> <{assign var="total" value=$total+1}> <{if $i == 4 || $total==$count}> <{assign var="i" value=0}> <{/if}> <{/foreach}> ``` 4. 十一、常用bootstrap ================================================================================================= ``` 版型 區塊 表格
<{$bootstrap}> <{$jquery}> <{$toolbar}> ``` 3. 常用樣板標籤 ``` $xoopsTpl->assign( "toolbar" , toolbar_bootstrap($interface_menu)) ; $xoopsTpl->assign( "bootstrap" , get_bootstrap()) ; $xoopsTpl->assign( "jquery" , get_jquery(true)) ; $xoopsTpl->assign( "isAdmin" , $isAdmin) ; <{$smarty.const._常數}> <{foreach item=xxx from=$ooo}> <{/foreach}> 分欄位 <{assign var="i" value=0}> <{assign var="total" value=1}> <{foreach item=class from=$data}> <{if $i==0}> <{/if}> 內容 <{assign var="i" value=$i+1}> <{assign var="total" value=$total+1}> <{if $i == 4 || $total==$count}> <{assign var="i" value=0}> <{/if}> <{/foreach}> ``` 4. 十一、常用bootstrap ================================================================================================= ``` 版型 區塊 表格
$xoopsTpl->assign( "toolbar" , toolbar_bootstrap($interface_menu)) ; $xoopsTpl->assign( "bootstrap" , get_bootstrap()) ; $xoopsTpl->assign( "jquery" , get_jquery(true)) ; $xoopsTpl->assign( "isAdmin" , $isAdmin) ; <{$smarty.const._常數}> <{foreach item=xxx from=$ooo}> <{/foreach}> 分欄位 <{assign var="i" value=0}> <{assign var="total" value=1}> <{foreach item=class from=$data}> <{if $i==0}> <{/if}> 內容 <{assign var="i" value=$i+1}> <{assign var="total" value=$total+1}> <{if $i == 4 || $total==$count}> <{assign var="i" value=0}> <{/if}> <{/foreach}> ``` 4. 十一、常用bootstrap ================================================================================================= ``` 版型 區塊 表格
版型 區塊 表格