[Typo3-dev] Follow-Up: Re: Display page in menu, regardless of login status.

Onno Schuit o.schuit at solin.nl
Tue Oct 25 10:49:47 CEST 2005


Hi All,


I cannot seem to get the "showAccessRestrictedPages"-feature to work *AT 
ALL*.

Please find my TS code included below.


Cheers,

Onno



temp.mainmenu = HMENU
temp.mainmenu {
	entryLevel = {$temp.entryLevel.Main}
	#1st Menu level
	1 = TMENU
	1 {
		wrap = <ul class="menu">|</ul>
		expAll = 1
		IFSUB = 1
		IFSUB.linkWrap = <li class="menuitem_NO"><div class="hasSub"><a 
href="#" onclick="swapitem(this);" class="arrow_right"><img border="0" 
height="11" width="13" src="images/empty.gif"/></a>|</div><ul>
		ACTIFSUB = 1
		ACTIFSUB.linkWrap = <li class="menuitem_ACT"><div class="hasSub"><a 
href="#" onclick="swapitem(this);" class="arrow_down"><img border="0" 
height="11" width="13" src="images/empty.gif"/></a>|</div><ul>
		
		#NO.linkWrap = <li class="menuitem_NO"><div class="noSub"><a href="#" 
onclick="swapitem(this);" class="arrow_right"><img border="0" 
height="11" width="13" src="images/empty.gif"/></a>|</div></li>
		NO.linkWrap = <li class="menuitem_NO"><div class="noSub"><img 
border="0" height="11" width="13" src="images/empty.gif"/>|</div></li>
		ACT = 1
		ACT.linkWrap = <li class="menuitem_ACT"><div class="noSub"><img 
border="0" height="11" width="13" src="images/empty.gif"/>|</div></li>

                 #Show access-restricted page in menu
                 showAccessRestrictedPages = 158
	}
	...



Keith Morrison wrote:
> Kasper,
> 
> I just wanted to follow up on this again, because I may have discovered 
> an issue with the implementation of this feature.  I've spent a good 
> amount of time trying to track down why ###RETURN_URL### isn't being 
> populated, and the issue becomes apparent when the call "$page = 
> $GLOBALS['TSFE']->sys_page->getPage" is called in t3lib_page.  Since 
> $disableGroupAccessCheck=FALSE is the default parameter setting, no 
> record will be returned to the function because you are trying to pull 
> up page information on a page that has been in some way marked for 
> access only when a user is logged in.  Proof-of-concept: the proper 
> return url is created if you hack t3lib_page and pass a parameter of 
> TRUE to override the default.  Anyway, by the time you get to this call, 
> the script doesn't know any longer that it should be passing that 
> override, because the information hasn't been passed along--and I can't 
> figure out a way to do it.
> 
> Note: I followed this by tracking calls, some of which passed through 
> realurl.  From what I can determine, this would also be an issue if 
> someone wasn't using realurl, because it looks like getPage needs to be 
> called in any instance.  However, the possibility exists that this is a 
> problem limited to realurl.  I may also be missing something obvious 
> that would fix this.
> 
> Thanks again,
> Keith




More information about the TYPO3-dev mailing list