do_html_header函数使用,discuz!x模版header.htm文件分析

/p>

“-//W3C//DTD XHTML 1.0 Transitional//EN”

“http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd”>

xmlns=”http://www.w3.org/1999/xhtml”>

content=”text/html; charset={CHARSET}” />

{if

!empty($topic['title'])}$topic['title'] {/if}{if

!empty($_G['home_tpl_titles'])}{loop $_G['home_tpl_titles']

$value}$value – {/loop}{/if}{if !empty($space[username])}

$space[username]- {/if}{if !empty($navtitle)}$navtitle{/if}

$_G['setting']['bbname'] $_G['setting']['seotitle'] – Powered by

Discuz!

\\标题,可去掉power by discuz!(不建议)

$_G['setting']['seohead']

content=”{if

!empty($metakeywords)}$metakeywords,{/if}$_G['setting']['seokeywords']”

/>

content=”{if !empty($metadescription)}$metadescription{/if}

$_G['setting']['bbname'] $_G['setting']['seodescription'] – Discuz!

Board” />

content=”Discuz! $_G['setting']['version']” />

content=”Discuz! Team and Comsenz UI Team” />

content=”2001-2010 Comsenz Inc.” />

name=”MSSmartTagsPreventParsing” content=”True”

/>

http-equiv=”MSThemeCompatible” content=”Yes”

/>

&& ($_G['basescript'] == ‘forum’ ||

$_G['basescript'] == ‘group’) &&

(CURMODULE == ‘index’ || CURMODULE == ‘forumdisplay’ || CURMODULE

==

‘group’)}–>$rsshead

{csstemplate}

STATICURL = ‘{STATICURL}’, IMGDIR = ‘{IMGDIR}’, VERHASH =

‘{VERHASH}’, charset = ‘{CHARSET}’, discuz_uid = ‘$_G[uid]‘,

cookiepre = ‘{$_G[config][cookie][cookiepre]}’, cookiedomain =

‘{$_G[config][cookie][cookiedomain]}’, cookiepath =

‘{$_G[config][cookie][cookiepath]}’, attackevasive =

‘{$_G[config][security][attackevasive]}’, disallowfloat =

‘{$_G[setting][disallowfloat]}’, creditnotice = ‘{if

$_G['setting']['creditnotice']}$_G['setting']['creditnames']{/if}’

‘forum’ || $_G['basescript'] == ‘group’}–>

‘home’}–>

‘userapp’}–>

‘portal’}–>

‘portal’ && $_GET['diy'] == ‘yes’

&& ($_G[mod] == ‘topic’ ||

$_G[group][allowdiy]) &&

!empty($_G['style']['tplfile'])}–>

&& ($_G[mod] == ‘topic’ ||

$_G[group][allowdiy]) &&

!empty($_G['style']['tplfile'])}–>{subtemplate

common/css_diy}

id=”nv_

&& !empty($_G['forum'])

&& $_G['forum']['status'] ==

3}–>group$_G[basescript]”>

&& $_G[group][allowdiy]

&& !empty($_G['style']['tplfile']))

|| (!empty($_G['style']['tplfile'])

&& $_G[mod]==’topic’

&& (($_G['group']['allowaddtopic']

&& $topic[uid]==$_G[uid]) ||

$_G[group][allowmanagetopic]))}–>

href=”javascript:openDiy();” title=”{lang

open_diy}”>

src=”{STATICURL}image/diy/panel-toggle.png” alt=”DIY”

/>

\\上a标记为DIY按钮,以下为diy代码部分

id=”append_parent”>

id=”ajaxwaitid”>

&& ($_G[mod] == ‘topic’ ||

$_G[group][allowdiy]) &&

!empty($_G['style']['tplfile'])}–>

{template common/header_diy}

($topic[useheader])}–>

{ad/headerbanner/wp a_h}\\diy代码结束

id=”hd”>

href=”index.php”

title=”$_G['setting']['bbname']“>{BOARDLOGO}

\\屋顶 or

banner,可修改banner的链接到哪里,banner的鼠标经过时显示的问题【现在为bbs name】

$_G['setting']['search']}–>

{eval $slist = array();}

$_G['setting']['search']['portal']['status']

&& ($_G['group']['allowsearch']

& 1 || $_G['adminid'] == 1)}–>{block

slist[portal]}

href=”javascript:;”>

for=”mod_article”>

id=”mod_article” name=”mod” value=”portal”{if CURSCRIPT ==

‘portal’} checked=”checked”{/if} />{lang

article}

{/block}

$_G['setting']['search']['forum']['status']

&& ($_G['group']['allowsearch']

& 2 || $_G['adminid'] == 1)}–>{block

slist[forum]}

href=”javascript:;”>

for=”mod_thread”>

id=”mod_thread” name=”mod” value=”forum”{if CURSCRIPT == ‘forum’}

checked=”checked”{/if}

/>$_G['setting']['navs'][2]['navname']

{/block}

$_G['setting']['search']['blog']['status']

&& ($_G['group']['allowsearch']

& 4 || $_G['adminid'] == 1)}–>{block

slist[blog]}

href=”javascript:;”>

for=”mod_blog”>

id=”mod_blog” name=”mod” value=”blog”{if CURSCRIPT == ‘home’

&& $do != ‘album’}

checked=”checked”{/if} />{lang

blog}

{/block}

$_G['setting']['search']['album']['status']

&& ($_G['group']['allowsearch']

& 8 || $_G['adminid'] == 1)}–>{block

slist[album]}

href=”javascript:;”>

for=”mod_album”>

id=”mod_album” name=”mod” value=”album”{if CURSCRIPT == ‘home’

&& $do == ‘album’}

checked=”checked”{/if} /> {lang

album}

{/block}

$_G['setting']['groupstatus'] &&

$_G['setting']['search']['group']['status']

&& ($_G['group']['allowsearch']

& 16 || $_G['adminid'] ==

1)}–>{block

slist[group]}

href=”javascript:;”>

for=”mod_group”>

id=”mod_group” name=”mod” value=”group”{if CURSCRIPT == ‘group’}

checked=”checked”{/if}

/>$_G['setting']['navs'][3]['navname']

{/block}

$slist}–>

autocomplete=”off” action=”search.php?searchsubmit=yes”

target=”_blank”>

type=”hidden” />

name=”formhash” value=”{FORMHASH}” />

value=”title” type=”hidden” />

id=”sctype”>{lang

search}

name=”srchtxt” id=”srchtxt” value=”{lang enter_content}”

prompt=”search_kw” autocomplete=”off” />

name=”searchsubmit” prompt=”search_submit” type=”submit”

value=”true”>{lang

search}

style=”display: none”>

  • {echo

implode(”, $slist);}

\\搜索框部分

id=”nv”>\\导航栏开始

$navsid $nav}–>

$nav['available']}–>

&&

!empty($_G['setting']['plugins']['jsmenu'])}–>

$nav[nav]

($nav['level'] == 1 && $_G['uid'])

|| ($nav['level'] == 2 &&

$_G['adminid'] > 0) || ($nav['level'] == 3

&& $_G['adminid'] ==

1)}–>$nav[nav]

!empty($_G['setting']['plugins']['jsmenu'])}–>

style=”display: none”>

$_G['setting']['plugins']['jsmenu'] $module}–>

($module['adminid'] &&

$_G['adminid'] > 0

&& $module['adminid']

>= $_G['adminid'])}–>

$module[url]

$_G['setting']['subnavs'] $subnav}–>

$subnav

\\导航栏结束

id=”mu”>\\页头分割线开始

$_G[setting][snavs][$_G[basescript]]}–>

$_G[setting][snavs][$_G[basescript]] $item}–>

$item
\\页头分割线结束

{ad/subnavbanner/a_mu}

id=”um”>\\”登录,注册||用户名-在线-我的中心-设置-提醒-短信息-退出”处代码开始

$_G['uid']}–>

href=”home.php?mod=space”

target=”_blank”>{$_G[member][username]}

\\用户名(加粗)

\\在线隐身的代码开始

$_G['group']['allowinvisible']}–>

id=”loginstatus”>

href=”member.php?mod=switchstatus” title=”{lang

login_switch_invisible_mode}”>

$_G['session']['invisible']}–>{lang

login_invisible_mode}{lang

login_normal_mode}

|\\间隔

href=”home.php?mod=space&do=home”>{lang

my_space}

\\我的中心

href=”home.php?mod=spacecp”>{lang

setup}

\\设置

|\\间隔再来

href=”home.php?mod=space&do=notice” id=”myprompt”

$_G[member][newprompt]}–>class=”new”>{lang

remind}

$_G[member][newprompt]}–>($_G[member][newprompt])

id=”myprompt_check”>

\\提示

|\\间隔

href=”home.php?mod=space&do=pm”

id=”pm_ntc”

$_G[member][newpm]}–>class=”new”>{lang

pm_center}

$_G[member][newpm]}–>($_G[member][newpm])

\\短信息

$_G['group']['allowmanagearticle'] || $_G['group']['allowdiy'] ||

in_array($_G['uid'],

$_G['setting']['ext_portalmanager'])}–>|

href=”portal.php?mod=portalcp”>{lang

portal_manage}

\\门户管理

&& $_G['group']['radminid']

>

1}–>|

href=”forum.php?mod=modcp&fid=$_G[fid]”

target=”_blank”>{lang

forum_manager}

\\广场管理

&& ($_G['group']['radminid'] == 1

||

$_G['member']['allowadmincp'])}–>|

href=”admin.php” target=”_blank”>{lang

admincp}

\\管理中心

|\\间隔

href=”member.php?mod=logging&action=logout&formhash={FORMHASH}”>{lang

logout}

\\退出

!empty($_G['cookie']['loginuser'])}–>

id=”loginuser”>$_G['cookie']['loginuser']

|

href=”member.php?mod=logging&action=login”>{lang

activation}

|

href=”member.php?mod=logging&action=logout&formhash={FORMHASH}”>{lang

logout}

\\登录….

href=”member.php?mod=register”>$_G['setting']['reglinkname']

|

href=”member.php?mod=logging&action=login”>{lang

login}

\\注册

\\判断结束…

{hook/global_header}

id=”wp”>\\中间部分代码开始..接着其他文件

-//W3C//DTD XHTML 1.0

Transitional//EN”

“http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd”>

xmlns=”http://www.w3.org/1999/xhtml”> 

 

content=”text/html; charset={CHARSET}”

/> 

{if

!empty($topic['title'])}$topic['title'] {/if}{if

!empty($_G['home_tpl_titles'])}{loop $_G['home_tpl_titles']

$value}$value – {/loop}{/if}{if !empty($space[username])}

$space[username]- {/if}{if !empty($navtitle)}$navtitle{/if}

$_G['setting']['bbname'] $_G['setting']['seotitle'] – Powered by

Discuz!

\\标题,可去掉power by

discuz!(不建议)

$_G['setting']['seohead'] 

!empty($metakeywords)}$metakeywords,{/if}$_G['setting']['seokeywords']”

/> 

content=”{if !empty($metadescription)}$metadescription{/if}

$_G['setting']['bbname'] $_G['setting']['seodescription'] – Discuz!

Board” /> 

content=”Discuz! $_G['setting']['version']”

/> 

content=”Discuz! Team and Comsenz UI Team”

/> 

content=”2001-2010 Comsenz Inc.”

/> 

name=”MSSmartTagsPreventParsing” content=”True”

/> 

http-equiv=”MSThemeCompatible” content=”Yes”

/> 

&& ($_G['basescript'] == ‘forum’ ||

$_G['basescript'] == ‘group’) &&

(CURMODULE == ‘index’ || CURMODULE == ‘forumdisplay’ || CURMODULE

==

‘group’)}–>$rsshead {csstemplate} 

STATICURL = ‘{STATICURL}’, IMGDIR = ‘{IMGDIR}’, VERHASH =

‘{VERHASH}’, charset = ‘{CHARSET}’, discuz_uid = ‘$_G[uid]‘,

cookiepre = ‘{$_G[config][cookie][cookiepre]}’, cookiedomain =

‘{$_G[config][cookie][cookiedomain]}’, cookiepath =

‘{$_G[config][cookie][cookiepath]}’, attackevasive =

‘{$_G[config][security][attackevasive]}’, disallowfloat =

‘{$_G[setting][disallowfloat]}’, creditnotice = ‘{if

$_G['setting']['creditnotice']}$_G['setting']['creditnames']{/if}’   

‘forum’ || $_G['basescript'] ==

‘group’}–> 

src=”{$_G[setting][jspath]}forum.js?{VERHASH}”> 

‘home’}–> 

src=”{$_G[setting][jspath]}home_cookie.js?{VERHASH}”> 

src=”{$_G[setting][jspath]}home_common.js?{VERHASH}”> 

src=”{$_G[setting][jspath]}home_face.js?{VERHASH}”> 

src=”{$_G[setting][jspath]}home_manage.js?{VERHASH}”> 

‘userapp’}–> 

src=”{$_G[setting][jspath]}home_common.js?{VERHASH}”> 

‘portal’}–> 

src=”{$_G[setting][jspath]}portal.js?{VERHASH}”> 

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值