[TYPO3-mvc] shared templates/partials? Or something like skin support for FLUID/FLOW3/ExtBase

Christine Gerpheide cgerpheide at gmail.com
Tue May 18 23:02:38 CEST 2010


2010/4/12 Franz Koch <typo3.RemoveForMessage at elements-net.de>

> Hey,
>
>
>  Did you notice, how the switch from index.html to index.txt is done in
>> the BlogExample. You just have toadd a format parameter to the URI:
>>
>> <f:link.action arguments="{blog : blog}" format="txt"
>> target="_blank">Show posts as plain text</f:link.action>
>>
>
> I also use mixed html/xml files in a already finished extension by simply
> defining the format parameter Jochen pointed to. And if you like to bind the
> format parameter to a certain pageType, you could preset the format in the
> config of extbase, so that you don't have to add it to URIs:
>
> xml = PAGE
> xml {
>        typeNum = 101
>        30 =< tt_content.list.20.yourExtKey_pi1
>        30 {
>                controller = DefaultXmlController
>                action = defaultXmlAction
>                format = xml
>        }
> }
>
> --
> kind regards,
> Franz Koch
>
>

Actually, I didn't know about the format parameter (or the TS to do it
according to pagetype :), but the problem we were still having is with
redirects inside the controller ($this->redirect('next')).  We ended up
overriding the redirect method so that it preserves the pagetype/format that
the original request, because when the request was made for the XML
pagetype/format, we wanted the response to be XML, regardless of whether
there was a redirect in between.

I'm not sure if this has changed by now (I am replying to a month old email
:), but if not... Is there ever a case where you wouldn't want the pagetype
or format to be preserved through a redirect?  If there isn't, then I guess
it would be a pretty simple patch (which I hopefully could provide).

Christine


More information about the TYPO3-project-typo3v4mvc mailing list