joomla中jdoc:include的介紹

 

jdoc:includephp

<jdoc:include type="component" />
<jdoc:include type="head" />
<jdoc:include type="installation" />
<jdoc:include type="message" />
<jdoc:include type="module" name="breadcrumbs" />
<jdoc:include type="module" name="menu" />
<jdoc:include type="module" name="submenu" style="rounded" id="submenu-box" />
<jdoc:include type="modules" name="debug" />
<jdoc:include type="modules" name="icon" />
<jdoc:include type="modules" name="left" style="rounded" />
<jdoc:include type="modules" name="left" style="xhtml" />
<jdoc:include type="modules" name="right" style="xhtml" />
<jdoc:include type="modules" name="status" />
<jdoc:include type="modules" name="syndicate" />
<jdoc:include type="modules" name="title" />
<jdoc:include type="modules" name="toolbar" />
<jdoc:include type="modules" name="top" />
<jdoc:include type="modules" name="top" style="xhtml" />
<jdoc:include type="modules" name="user1" style="xhtml" />
<jdoc:include type="modules" name="user2" style="xhtml" />
<jdoc:include type="modules" name="user3" />
<jdoc:include type="modules" name="user4" />
html

type 屬性ide

jdoc:include 元素中的type屬性指定要渲染的內容類型,屬性值能夠是component,head,installation,message,module,modulesdebug


component
頁面內容主輸出部分,在模板頁面<body>元素中應該只出現一次。
設計

head
填充當前頁的style, script,meta的相關元素,應該在模板的<head>元素中只出現一次。
component

installation
僅僅在安裝模板中有用,在前臺和後臺的模板中沒有用到,某種程度上與 component類型類似,渲染安裝步驟中中的一個頁面主內容。
orm

message
在模板的<body>元素中只出現一次,填充系統或者報錯信息。
htm

module
渲染由name屬性指定的單一模塊,模塊必須是發佈的而且當前用戶有權訪問,還能夠有layout以及controller屬性。
blog

modules
渲染模板中全部指定名稱的模塊,模塊必須是發佈的而且當前用戶有權訪問,還能夠有layout以及controller屬性。
ip


style 屬性

對於module 和modules 類型,style是一個可選屬性,這一屬性指定了模塊被渲染風格,若是沒指定style,默認是none

/templates/system/html/modules.php 聲明瞭標準的style:table,horz,xhtml,rounded,outline 模板設計者能夠在如下文件自定義style /user-template/html/modules.php.

相關文章
相關標籤/搜索