Zen TYPO3 Forum

Our TYPO3 forum is available for freelancers, professionals and clients new to TYPO3 to discuss Basic TYPO3 templating, Typoscript, extension installation, administration and help with subscription templates. Please register for an account to post.

All Categories > TYPO3 General Discussion > Templates > css menu in typo script, explain me please
Total Posts: 1 - Pages (1): [1]
Author: MikeKlemin
Posted: Nov 02 2007 - 02:44 AM
Subject: css menu in typo script, explain me please
Hallo,
Can you guys explain me how does the typo script works. I am not professional just a amateur web programming with some skills in php and dhtml/css.
Say I have a HTML menu as follows
<ul id="menu_1">
<li class="first"><a href="#">Home</a></li>
<li class="frst"><a href="#">About</a>
<ul>
<li><a href="#">History</a></li>
<li><a href="#">History 2</a></li>
<li><a href="#">History 2</a></li>
</ul>
</li>
<li class="first"><a href="#">Contact Us</a>
<ul>
<li><a href="#"></a>Contact Us</li>
<li><a href="#">Contact Us2</a></li>
<li><a href="#">Contact Us3</a></li>
<li><a href="#">Contact Us4</a></li>
</ul>
</li>
</ul>

I have searched different forums, because I was not able to think the script out from my head, I tried hard...
So I found a code, and surprisingly it worked quite good besides few things.
The TS:

temp.menu_1 = HMENU
temp.menu_1.1 = TMENU
temp.menu_1.1 {
noBlur = 1
expAll = 1
NO.wrapItemAndSub = <li> | </li>
IFSUB=1
IFSUB {
wrapItemAndSub = <li> | </li>
}
}

# First dropdown Menu configuration
temp.menu_1.2 = TMENU
temp.menu_1.2 {
noBlur = 1
expAll = 1
IFSUB=1
IFSUB {
wrapItemAndSub = <li> | </li>
}
}

Can you explain me
How does this script works?! I really can find any logic... :-(

1) How does typo script knows where menu starts in my html template? Does it knows that because of menu_1 name either for menu in TS and menu in html?
2) How does typo script knows where the drop down menu starts in my html template???
3) What does IFSUB does? Really, TS reference doesnt helped me at all :-(
4) How can I put class="first" in the first elements (li) in my menu?

I am sorry if my questions can be related to RTFM, but I did read it all, just can't understand.
Thank you!
Total Posts: 1 - Pages (1): [1]
You must login to post a message to this conference.

 

CHC Forum provided by Cast Iron Coding

TYPO3 Support