Hi Leute,
ich kenne mich leider noch nicht wirklich gut mit Typo3 aus, habe dafür aber schon relativ viel hinbekommen.
Ich habe größtenteils die Anleitung Modern Template Building aus der Doku befolgt und nun ein 3 spaltiges Template entworfen.
Linke Spalte Navi, Mitte ist content und rechts soll immer ein statisches Element angezeigt werden. Ich dachte mir das könnte eine Typo3-Page sein.
Also habe ich jetzt eine Page gemacht mit der id=13 und die möchte ich jetzt dort dargestellt haben. Das ganze ist aber irgendwie nicht so leicht.
Hier der Code:
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/Strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="de">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<link href="main.css" rel="stylesheet" type="text/css" media="screen" />
<title>Rebecca Liljeberg Online</title>
</head>
<body>
<div id="rahmen">
<div id="header"><img src="header.jpg" alt="Rebecca Liljeberg Online - Header" width="950" height="150" /></div>
<div id="left">
<div id="menu_1">
<div class="menu1-level1-no"><a href="#" class="nav">Menu item 1</a></div>
<div class="menu1-level1-no"><a href="#" class="nav">Menu item 2</a></div>
<div class="menu1-level1-act"><a href="#" class="nav">Menu item 3 (act)</a></div>
<div class="menu1-level2-no"><a href="#" class="nav">Level 2 item</a></div>
<div class="menu1-level2-no"><a href="#" class="nav">Level 2 item</a></div>
<div class="menu1-level2-act"><a href="#" class="nav">Level 2 item (act)</a></div>
<div class="menu1-level1-no"><a href="#" class="nav">Menu item 2</a></div>
</div>
<div id="right"></div>
</div>
<div id="content">
Content<br />Content<br />Content<br />Content<br />Content<br />Content<br />Content<br />Content<br />
Content<br />Content<br />Content<br />Content<br />Content<br />Content<br />Content<br />Content<br />
Content<br />Content<br />Content<br />Content<br />Content<br />Content<br />Content<br />Content<br />
Content<br />Content<br />Content<br />Content<br />Content<br />Content<br />Content<br />Content<br />
Content<br />Content<br />Content<br />Content<br />Content<br />Content<br />Content<br />Content<br />
</div>
<br style="clear:both;" />
</div>
</body>
</html>
und der Typo3-Code
# Configuring the Auto-Parser for main template:
plugin.tx_automaketemplate_pi1 {
# Read the template file:
content = FILE
content.file = fileadmin/templates/rebtypo3_1/template.html
# 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
DIV.all = 1
}
# Prefix all relative paths with this value:
relPathPrefix = fileadmin/templates/rebtypo3_1/
}
# Menu 1 cObject
temp.menu_1 = HMENU
# First level menu-object, textual
temp.menu_1.1 = TMENU
temp.menu_1.1 {
# Normal state properties
NO.allWrap = <div class="menu1-level1-no"> | </div>
# Enable active state and set properties:
ACT = 1
ACT.allWrap = <div class="menu1-level1-act"> | </div>
}
# Second level menu-object, textual
temp.menu_1.2 = TMENU
temp.menu_1.2 {
# Normal state properties
NO.allWrap = <div class="menu1-level2-no"> | </div>
# Enable active state and set properties:
ACT = 1
ACT.allWrap = <div class="menu1-level2-act"> | </div>
}
# Main TEMPLATE cObject for the BODY
temp.mainTemplate = TEMPLATE
temp.mainTemplate {
# Feeding the content from the Auto-parser to the TEMPLATE cObject:
template =< plugin.tx_automaketemplate_pi1
# Select only the content between the <body>-tags
workOnSubpart = DOCUMENT_BODY
# Substitute the ###menu_1### subpart with dynamic menu:
subparts.menu_1 < temp.menu_1
# Substitute the ###content### subpart with dynamic content:
subparts.content < styles.content.get
}
# Main TEMPLATE cObject for the HEAD
temp.headTemplate = TEMPLATE
temp.headTemplate {
# Feeding the content from the Auto-parser 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
config.doctype = xhtml_trans
config.xhtml_cleaning = all
# Copying the content from TEMPLATE for <body>-section:
page.10 < temp.mainTemplate
# Copying the content from TEMPLATE for <head>-section:
page.headerData.10 < temp.headTemplate
plugin.tx_lzgallery_pi1.gallery.default.filename = 0
plugin.tx_lzgallery_pi1.gallery.default.filename = 1
config.language=de
config.locale_all=de_DE
#den Default Stylesheet leeren:
plugin.tx_lzgallery_pi1_simple._CSS_DEFAULT_STYLE >
plugin.tx_lzgallery_pi1._CSS_DEFAULT_STYLE >
# kein menu
plugin.tx_lzgallery_pi1 < plugin.tx_lzgallery_pi1_simple
plugin.tx_lzgallery_pi1 {
piVarPresets{
clickmode = samewindow_max
colrows = 4x4
maxwidth = 500
}
piVarOptions{
clickmode = samewindow_max
colrows = 1x1,3x3,5x5
maxwidth = 500
}
}
#popup window for images
tt_content.image.20.1.imageLinkWrap.JSwindow.expand = 0,0
tt_content.image.20.1.imageLinkWrap.bodyTag = <BODY style="margin: 0;
background: #FFFFFF;>
#popup window for images in 'text with image'
tt_content.textpic.20.1.imageLinkWrap < tt_content.image.20.1.imageLinkWrap
Ich wäre für jede Hilfe dankbar. 🙂
Schönen Gruß,
Sebi