[TYPO3] Changed page title not available in stdWrap.data

Christopher Torgalson bedlamhotel at gmail.com
Tue May 1 18:20:09 CEST 2007


Hi Francois,

On 5/1/07, Francois Suter <fsuter at cobweb.ch> wrote:
> Hi all,
>
> In an extension I am trying to change the page title using a syntax I
> found in the tt_news extension:
>
> $GLOBALS['TSFE']->page['title'] = 'List of organisations';
>
> In my pages, I have also the following TS:
>
> lib.cw_breadcrumb = COA
> lib.cw_breadcrumb {
>         10 = HMENU
>         ...
>         20 = TEXT
>         20.data = page:title
>         ...
> }
>
> The TS output uses the original page title and not the one modified
> by my script. I also notice that the title appearing in the window is
> not changed either. It seems that just trying to change the value of
> $GLOBALS['TSFE']->page['title'] is not enough. What am I missing?


The TS you're using directly references the pages table, but you have
/not/ modified this with your code (this is probably a good thing if
your extension, like tt_news, shows different content using the same
page record).

You just need to alter your TS a bit--I think this should work:

20.data = TSFE:title

...though I'm not sure if the scope is right. If that doesn't work,
then this should:

20.data = TSFE:page|title




-- 
Christopher Torgalson
http://www.typo3apprentice.com/


More information about the TYPO3-english mailing list