[Typo3] Showing a menu even if the page is restricted

Courcy Michael courcy.michael at wanadoo.fr
Thu Sep 15 15:42:31 CEST 2005


Hi JoH
Thanks a lot for your answser.
But if I clearly understand your answer I think your solution don't take 
in account the fact that I want to give the power to the writer 
(actually the landlord of the site) to put restriction at the *page 
level*  beside that should be  *arbitrary in the tree*.

What you propose bellow :

[loginUser = *]
page.10.subparts.content < styles.content.get
[else]
page.10.subparts.content < temp.otherContent
[global]

Make sens if (AND ONLY IF) I already know which part of the tree is going to be restricted....

I think this is going to be my next extension giving the hability to force the apparition of the menu
Something like this 

temp.menu_1 = HMENU
temp.menu_1.1 = TMENU
temp.menu_1.1 {
    NO.allWrap = <div class="menu1-level1-no"> | </div>
    # *****NEW FEATURE******
    force_restriction = 1 
}

Cheers
Michael.






JoH wrote:

>>Well, I can understand it looks strange to display a menu of a page
>>wich is  restricted.
>>The reason is actually a commercial one.
>>We want to show to the new user (visitor)  that some informations
>>could be reach only if they suscribe.
>>But to achieve this goal we need to **show** the page exists...
>>    
>>
>
>Well - it's easier than you might have thought:
>
>Use TypoScript conditions for your markers/subparts.
>Since it's the content that is restricted and not the page itself you can do
>something like this in an ext+ template of the entrypage for the restricted
>area:
>
>temp.otherContent = COA
>temp.otherContent {
>    10 = TEXT
>    10 {
>        # Your additional message here
>        #to explain why a user should login
>    }
>    20 < styles.content.loginform
>}
>
>[loginUser = *]
>page.10.subparts.content < styles.content.get
>[else]
>page.10.subparts.content < temp.otherContent
>[global]
>
>Since otherContent is a COA you can insert as many Elements, Records or
>other stuff as you like.
>You can even create other elements for the different subparts or markers you
>are using.
>Another approach is to use different columns for restricted and non
>restricted content.
>So your Editors can insert different "non restricted" content for each page.
>The only thing that's always added is the loginform.
>
>temp.otherContent = COA
>temp.otherContent {
>    10 < styles.content.getLeft
>    20 < styles.content.loginform
>}
>
>[loginUser = *]
>page.10.subparts.content < styles.content.get
>[else]
>page.10.subparts.content < temp.otherContent
>[global]
>
>You see like in most cases the solution is pure TypoScript and no extra PHP
>
>Joey
>
>  
>




More information about the TYPO3-english mailing list