[TYPO3-english] Special content in submenu

Tyler Kraft tyler.kraft at netefficiency.co.uk
Wed Oct 29 12:30:08 CET 2008


Hi

No that's not true, you need to read a bit more carefully ;-)

It also accepts stdWrap! So you can then use any property of stdWrap, 
and *it* has user functions and content objects. With this you've just 
opened a door to being able to do almost anything you want.

1.ACT.after.cObject  < plugin.tx_myplugin_pi1

( Or it might be 1.ACT.after.stdWrap.cObject  < plugin.tx_myplugin_pi1 )

You could even build a whole other COA there if you need to:

1.ACT.after.cObject  = COA
1.ACT.after.cObject.10 = HTML
1.ACT.after.cObject.10.value = ...
1.ACT.after.cObject.20 < plugin.tx_myplugin_pi1
1.ACT.after.cObject.30 = CONTENT

And then like that you could apply a if test to the COA
1.ACT.after.cObject.if{
	value = 7
	equals.field=section_frame
}

hth
Tyler

Daniel Calderini wrote:
> Thanks for your answer.
> 
> I tried to place the Plugin content in the after property with the 
> following Typoscript:
> 
> menu = COA
> menu {
>     10 = HMENU
>     10 {
>         entryLevel = 1
>        
>         1 = TMENU
>         1.wrap = <ul> | </ul>
> 
>         1.NO = 1
>         1.NO.allWrap = <li class="off"> | </li>
>            
>         1.ACT = 1
>         1.ACT.wrapItemAndSub = <li class="on"> | </li>
>         1.ACT.after < plugin.tx_myplugin_pi1
>     }
> }
> 
> And the result displayed is:
> 
> <ul>
>     <li class="off"><a>Page 1</a></li>
>     <li class="on"><a>Page 2</a>USER</li>
>     <li class="off"><a>Page 3</a></li>
> </ul>
> 
> This is quite logical as the after property of TMENU only accepts HTML 
> data type.
> http://typo3.org/documentation/document-library/references/doc_core_tsref/4.1.0/view/10/8/ 
> 
> 
> Is my Typoscript wrong or is there another way to do this?
> 
> 
> 
> Le 28/10/2008 12:07 :
>> Hi
>>
>> You could use the after object of the menu item in the ACT state and 
>> an if statement
>>
>> hope that helps
>> Tyler
>>
>>
>>
>> Daniel Calderini wrote:
>>> Hi list,
>>>
>>> I want to display the menu of the following page tree:
>>>
>>> - Page 1
>>> -- Subpage 1
>>> -- Subpage 2
>>> - Page 2
>>> - Page 3
>>> -- Subpage 3
>>>
>>> If "Page 1" is active, it will display a normal menu:
>>>
>>> - Page 1
>>> -- Subpage 1
>>> -- Subpage 2
>>> - Page 2
>>> - Page 3
>>>
>>> The same goes for "Page 3".
>>>
>>> Here is my problem: if "Page 2" is active, I want some special 
>>> content (which comes from a plugin) to be inserted between "Page 2" 
>>> and "Page 3"
>>>
>>> - Page 1
>>> - Page 2
>>> -- SOME CONTENT FROM PLUGIN
>>> - Page 3
>>>
>>>
>>> Is there a simple way to achieve this, or do I have to extend the 
>>> tslib_menu class ?
>>>
>>> Thanks and regards
>>> Daniel Calderini


More information about the TYPO3-english mailing list