[TYPO3] TMENU from other table than 'pages'

Peter Klein peter at umloud.dk
Sat May 5 12:49:44 CEST 2007


Hi Rens. Try this script:
http://www.typo3wizard.com/en/snippets/menus/create-menus-using-data-from-other-tables-than-pages.html

Then in the TS setup, change:

typolink.parameter.field = www

Into:

typolink.parameter = 29

--
Peter Klein / Umloud Untd


"Rens Admiraal" <typo3 at ambitiondesign.nl> wrote in message 
news:mailman.199423.1178359876.21067.typo3-english at lists.netfielders.de...
> Hi all,
>
> I'm trying to make a TMENU from records stored in another table than  the 
> 'pages' table. Doing that I encouter a little problem :-(
>
> I've used the following post as a resource: http:// 
> lists.netfielders.de/pipermail/typo3-english/2007-January/035637.html
>
> The database structure is as follows:
> tablename: e.g. table
> fields: uid, pid, pgroup, title
>
> The uid, title and pid fields do what they normally do in typo, and 
> pgroup is the column I use in my script. All items showed in the menu 
> must have pgroup=0
>
>
> So far, so good. The only thing I just can't accomplish is creating  the 
> correct link. The link must point to a page id which has nothing  to do 
> with this table, and has a constant value of 29. With 
> stdWrap.typolink.additionalParams I try to add &pgroup=uid (in which  uid 
> has to be replaced by the value of field:uid), but it just  doesn't 
> work...
>
> The menu constantly makes the following link: index.php?id=uid (and 
> again, uid = field:uid)
>
> This is the TypoScript I use (menuFunc.php contains the script of  Kasper 
> which you can find in the message I refer to above):
>
> page.includeLibs.usermenu = fileadmin/menuFunc.php
>
> temp.testmenu = HMENU
> temp.testmenu.1 = TMENU
> temp.testmenu.1 {
>     expAll = 0
>     wrap = <ul>|</ul>
>     itemArrayProcFunc = user_itemArrayProcFuncTest
>     itemArrayProcFunc.userFunc.oe_table = table
>     itemArrayProcFunc.userFunc.select.pidInList = 26
>     itemArrayProcFunc.userFunc.select.orderBy = sorting
>     itemArrayProcFunc.userFunc.select.where = pgroup=0
>     NO {
>        ATagBeforeWrap = 0
>        linkWrap = <li>|</li>
>        stdWrap.data = field:title
>        stdWrap.typolink.parameter.data = 29
>        stdWrap.typolink.additionalParams = field:uid
>        stdWrap.typolink.additionalParams.wrap= &pgroup=|
>       #stdWrap.data = debug:data
>    }
> } 




More information about the TYPO3-english mailing list