Months Archive August 2009

Mit diesem TypoScript Snippsel kann man das aktuelle Datum auf einer Website darstellen. Mit der Php Funktion strftime kann man das Datum beliebig formatieren.
// TYPO3 Setup
tmp.date = TEXT
tmp.date {
data = date : U
strftime = %A, %e. %B %Y
}
Hier eine kurze Erklärung zu strftime:
%A = Sonntag bis Samstag
%e = 1 bis 31
%B = Januar bis Dezember
%Y = Jahr: 2009
Mehr dazu findet ihr auf php.net/strftime
Die strftime-Formatangabe ‘%A, %e. %B %Y’ in diesem Beispiel erzeugt eine Ausgabe des Datums im Format ‘Freitag, 14. August 2009′.
Tags: php, ts, typo3, typoscript
Kategorie typo3 | 0 comments

Diesmal ein Codesnippsel für ein Grafisches Listen Menu mit Typoscript für mehrere Levels. Dieses Menu ist lauffähig und natürlich noch ausbaufähig.
// TYPO3 Setup
// mainmenu
lib.mainmenu = HMENU
lib.mainmenu {
entryLevel = 0
1 = GMENU
1 {
useLargestItemY = 1
noBlur = 1
expAll = 0
accessKey = 0
wrap =
<ul>|</ul>
NO = 1
NO {
ATagTitle.field = subtitle // title // description
allWrap =
<li>|</li>
XY = [10.w]+4,[10.h]+6
transparentBackground = 1
backColor = #000
10 = TEXT
10 {
text.field = title
offset = 0,16
fontColor = #ffffff
niceText = 0
align = center
fontFile = fileadmin/templates/fonts/verdanab.ttf
fontSize = 11
}
}
RO < .NO
RO = 1
RO.10 {
fontColor = #78d200
}
ACT < .RO
ACT = 1
ACT.10 {
fontColor = #78d200
fontFile = fileadmin/templates/fonts/verdanab.ttf
}
}
2 < .1
2 = GMENU
2 {
wrap =
<ul class="level2">|</ul>
}
}
Tags: menu, ts, typo3, typoscript
Kategorie typo3 | 0 comments








