Hallo,
ich habe nach dem Template-Tutorial ein Template zusammengebastelt, welches soweit auch gut funktioniert.
Das Problem ist jedoch, daß alle <br />-Tags umgewandelt werden in <p>-Tags. Das ist leider nicht so gut.
Hier mal mein Template:
# Configuring the Auto-Parser:
plugin.tx_automaketemplate_pi1 {
# Read the template file:
content = FILE
content.file = fileadmin/template/template.htm
# Here we define which elements in the HTML that
# should be wrapped in subpart-comments:
elements {
BODY.all = 1
BODY.all.subpartMarker = DOCUMENT_BODY
HEAD.all = 1
HEAD.all.subpartMarker = DOCUMENT_HEADER
HEAD.rmTagSections = title
TD.all = 1
TR.all = 1
}
# Prefix all relative paths with this value:
relPathPrefix = fileadmin/template/
}
# Main Menu cObject
temp.mnu_main = HMENU
# First level menu-object, textual
temp.mnu_main.1 = TMENU
temp.mnu_main.1{
# Normal state properties
NO.allWrap = <div class="mnu_no_main">|</div>
NO.stdWrap.htmlSpecialChars = 1
# Enable active state and set properties:
ACT = 1
ACT.stdWrap.htmlSpecialChars = 1
ACT.allWrap = <div class="mnu_act_main">|</div>
}
# Second level menu-object, textual
temp.mnu_main.2 = TMENU
temp.mnu_main.2{
# Normal state properties
NO.allWrap = <div class="mnu_no_submain">|</div>
NO.stdWrap.htmlSpecialChars = 1
# Enable active state and set properties:
ACT = 1
ACT.stdWrap.htmlSpecialChars = 1
ACT.allWrap = <div class="mnu_act_submain">|</div>
}
# Menu 3 cObject
temp.mnu_info = HMENU
temp.mnu_info.special = directory
temp.mnu_info.special.value = 2
temp.mnu_info.wrap = <td><div align="right"><img src="fileadmin/template/img/ecke.gif" width="16" height="16" alt="" /></div></td>|
# First level menu-object, textual
temp.mnu_info.1 = TMENU
temp.mnu_info.1 {
# Normal state properties
NO.allWrap = <td class="mnu_no_v">|</td>
NO.stdWrap.htmlSpecialChars = 1
# Enable active state and set properties:
ACT = 1
ACT.stdWrap.htmlSpecialChars = 1
ACT.allWrap = <td class="mnu_act_v">|</td>
}
#Main TEMPLATE cObject for the BODY
temp.mainTemplate = TEMPLATE
temp.mainTemplate{
# Feeding the content from the AutoParser to the TEMPALTE cObject:
template =< plugin.tx_automaketemplate_pi1
# Select only the content between the <body>-tags
workOnSubpart = DOCUMENT_BODY
# Substitute the ###mnu_main### subpart with dynamic menu:
subparts.mnu_main < temp.mnu_main
# Substitute the ###mnu_info### subpart with dynamic menu:
subparts.mnu_info < temp.mnu_info
# Substitute the ###content### subpart with some example content:
subparts.content < styles.content.get
}
#Main TEMPLATE cObject for the HEAD
temp.headTemplate = TEMPLATE
temp.headTemplate{
# Feeding the content from the AutoParser to the TEMPLATE cObject:
template =< plugin.tx_automaketemplate_pi1
# Select only the content between the <head>-tags
workOnSubpart = DOCUMENT_HEADER
}
# Default PAGE object:
page = PAGE
page.typeNum = 0
# Copying the content from TEMPALTE for the <body>-section:
page.10 < temp.mainTemplate
# Copying the content from TEMPLATE for the <head>-section:
page.headerData.10 < temp.headTemplate
page .config.doctype = xhtml_trans
Kann ich hier noch irgendetwas ändern, damit auch normale Zeilenumrüche im Content übernommen werden. Es ist sehr wichtig für mich dieses Problem in den Griff zu bekommen.
mfg
Reiner