[TYPO3-core] RFC #13634: ext_typoscript_setup.txt cannot be overriden by static files on the same level

Fabrizio Branca news at _REMOVETHIS_fabrizio-branca.de
Tue Nov 9 21:23:23 CET 2010


Hi,

there were some +1 and a v2 of this patch but nothing happend. I still 
like this option and would like to have it in 4.5. So here's the next try:

I created a new patch that applies on the current trunk (the old one 
didn't) based on Bennis v2 with some additional comments.

Short summary what is happening here:

Currently t3lib_TStemplate::includeStaticTypoScriptSources() simply 
calls t3lib_TStemplate::addExtensionStatics() after including the static 
files and addExtensionStatics() checks (based on static_file_mode = 0 or 
1) if it should process the extension statics or not (in case of 
static_file_mode == 2 nothing will be included).

I see the need that it should be possible to include those extension 
statics _before_ include the static files so I added a new option 
static_file_mode == 3 "Include before static and static from extensions 
if Root-flag is set" allowing to do this. What I do is to move the check 
from within addExtensionStatics() to includeStaticTypoScriptSources() 
and depending on the value of static_file_mode I call 
addExtensionStatics() before or after including the static files (or newer).

This allows you to have your typoscript in templates coming from 
extensions while overwriting the values in the template record. (Also 
see original post below...)

Any feedback welcome.

Bye,

Fabrizio.



On 23.02.2010 16:57, Fabrizio Branca wrote:
> This is an SVN patch request.
>
> Type: Bugfix / New feature?
>
> Bugtracker references:
> http://bugs.typo3.org/view.php?id=13634
>
> Branches:
> trunk, maybe 4_3 aswell?
>
> Problem:
> Some extension still deliver ext_typoscript_setup.txt (amongst them some
> popular ones like templavoila and new ones like felogin...). In the
> sys_template record you can choose
> - whether to not include them at all (Never include before this template
> record)
> - whether to always include them
> - or to include them only if the template is a root template.
> In any case (when include) the templates will be included _after_ the
> static ones and the static ones from extensions. This makes it
> impossible to override settings there from within a static template
> (without having a second template on the next level)
>
> Solution:
> Offer a new option that includes those templates if the Root-Flag is
> set, but includes them before all other templates (so you can overwrite
> them).
>
> Notes:
> Apply the patch, install an extension with ext_typoscript_setup.txt and
> tehn have a look at the order of templates in the template analyzer with
> the different options.
>
> Bye,
>
> Fabrizio

-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: 13634_v3.patch
URL: <http://lists.typo3.org/pipermail/typo3-team-core/attachments/20101109/dc4a9ab6/attachment.txt>


More information about the TYPO3-team-core mailing list