[TYPO3] Example for 'userdefined' for HMENU

Tapio Markula tapio.markula at dnainternet.net
Fri Jun 9 12:05:16 CEST 2006


Peter Klein wrote:
> Hi Tapio. You can find a very simple example I wrote a while ago, here:
> http://www.typo3wizard.com/en/snippets/menus/create-menus-using-data-from-other-tables-than-pages.html
> 

Ok. Because I was'n familiar using userdefined
I just made a direct hack to class.tslib_menu.php
				case 'updated':
...

						switch($mode)	{
							
							case 'newuntil':
...
						}
							
// allow to list also pages, which are normally hidden -
				
if ($this->conf['special.']['excludeNavHide']) {
	$extraWhere = ' AND pages.nav_hide=0';
}
						
						$thisTime=gettimeofday();
$thisTime=$thisTime['sec'];
if ($this->conf['special.']['beforeCurrentTime']) {
	$extraWhere = ' AND pages.newUntil<='.$thisTime;
	}

The idea of this hack is that it list pages, which should be
updated (date of newUntil is older than the currect time)

(because that file is often changes XCLASSing
is not a working idea).



More information about the TYPO3-english mailing list