Ich habe im TS Config ein Menü mit HMENU / TMENU erstellt:
### temp.MENU_SUB
temp.MENU_SUB = HMENU
temp.MENU_SUB {
entryLevel = 2
expAll = 0
1 = TMENU
1 {
noBlur = 1
wrap = <ul>|</ul>
NO.wrapItemAndSub = <li>|</li>
ATagTitle.field = title
ACT <.NO
ACT = 1
ACT.ATagParams = class="active"
}
2 < .1
2 {
wrap = <ul>|</ul>
ACT.ATagParams = class="active"
}
Nun möchte ich gerne, dass alle Links dieses Menüs mit einem Anker versehen werden (z.B. index.php?id=123#Mainarea). In meinem Fall wäre der Anker statisch, also für alle Links gleich.
Geht das?
Danke und lg,
Gerfried
Hi,
versuche es mal so:
### temp.MENU_SUB
temp.MENU_SUB = HMENU
temp.MENU_SUB {
entryLevel = 2
expAll = 0
1 = TMENU
1 {
noBlur = 1
wrap = <ul>|</ul>
NO{
wrapItemAndSub = <li>|</li>
stdWrap.cObject = TEXT
stdWrap.cObject{
field = title // sub_title
typolink{
parameter.field = uid
section = Mainarea
}
}
}
ATagTitle.field = title
ACT <.NO
ACT = 1
ACT.ATagParams = class="active"
}
2 < .1
2 {
wrap = <ul>|</ul>
ACT.ATagParams = class="active"
}
}
😃
Perfekt. Tausend Dank!
lg,
Gerfried :p
Hallo Freunde,
die beschriebene Lösung funktioniert zwar super, aber leider gehen damit die "active" Markierungen verloren.
Bitte wieder mal um Hilfe... :-)
lg,
Gerfried
Hab's gerade selbst herausgefunden:
Anstatt
ACT < .NO
schreibe ich
ACT {
wrapItemAndSub = <li>|</li>
}
und schon passt's wieder 8-)