Difference between revisions of "Module chrome/zh-tw"
From Joomla! Documentation
Line 2: | Line 2: | ||
{{Chunk:Module chrome/zh-tw}} | {{Chunk:Module chrome/zh-tw}} | ||
− | '''另見''' [[Standard Module Chromes|標準模組區塊]] | + | '''另見''' [[S:MyLanguage/Standard Module Chromes|標準模組區塊]] |
<noinclude> | <noinclude> |
Latest revision as of 20:45, 4 February 2021
模組區塊允許佈景主題設計師能控制模組在佈景主題中出現時的樣子。質言之,在每一個模組出現的前頭、後頭或是本身,它都包含了一個預先定義的HTML,這有助於使用 CSS 來進行風格設計。模組區塊常常被用於設計模組的邊框,特別是有圓角的,然而當然能做的遠遠不僅是這些。
模組區塊是由 'style' 屬性來決定的,在呼叫模組的聲明中也能看到。例如,以下的聲明可以被用於主要佈景主題的 index.php 檔案,來插入模組到 'user1' 位置並套用到名為 'custom' 的模組區塊:
<jdoc:include type="modules" name="user1" style="custom" />
您可以看到模組區塊被套用到每一個在這個位置的模組,換言之,如果您想要在一個欄中放置兩個模組,但像要他們有不同的模組區,那麼您需要設定兩個不同的位置( 'positions') (例如 'user1' 以及 'user2').
The standard Joomla! 1.5+ package includes six default Module chrome styles. However, the flexibility of the template system means that you are not limited to these styles - it's very easy to create as many new styles as you want!
另見 標準模組區塊