[TYPO3-english] constants.txt versus ext_typoscript_constants.txt

Leen Strijk leenstrijk at tomaatnet.nl
Fri Nov 11 15:56:13 CET 2011

Hi Peter,

So far understood.
So it's the ext_typoscript_constants file that is deprecated.
I was under the impression that it was also the other way that was not 
preferred anymore, what makes no sence at all, and kind of implied that 
only flexforms were to be used.

So I have included the file with : 
I can see the keys and values in the BE constants, but in the script no 
data will be available. it should be with $this->conf but only the setup 
data apears while debugging.

I have been searching for a long time now and i am really stuck.
Whatever i try I can't get the values from either file

btw I am on a local server(offcource) typo3 5.7

On 11-11-2011 10:33, Peter Niederlag wrote:
> Hi Leen,
> in fact both approaches can be used in parallel:
> 1)
> ext_typoscript_constants.txt will be loaded/included whenever it is
> available. All included code is therfor included globally just by
> installation of the extension. This approach is officially marked
> "deprecated" but widley used and IMO very useful.
> 2)
> register some folder for TS-code in ext_tables.php:
> t3lib_extMgm::addStaticFile($_EXTKEY,'pi1/static','my_extension');
> pi1/static/setup.txt constants.txt ... will be made available as
> "Include Static from extensions" under the label "my_extension" when you
> edit a sys_template (TypoScript-template) in the BE on the "Include"(??)
> tab.
> This code is only executed when the user activly includes this template.
> hth and Greets,
> Peter
> Am 10.11.2011 20:27, schrieb Leen Strijk:
>> Hi,
>> I was having a problem with the constants.txt file.
>> After a lot of searching I finally realised that my problem was that I
>> also had a ext_typoscript_constants.txt file in the extension.
>> So all the time I was looking at the constants.txt while the ext was
>> looking at the ext_typoscript_constants.txt.
>> I want to use the constants.txt but when i remove the
>> ext_typoscript_constants.txt file the calues from constants.txt won't
>> get read.
>> I have t3lib_extMgm::addStaticFile($_EXTKEY,'pi1/static','my_extension');
>> in ex_tables.php
>> I read the following in another old topic
>> [quote]
>> Hi Tapio, Once you install an extension, and it uses the old method
>> (ext_typoscript_constants.txt / ext_typoscript_setup.txt), then the TS is
>> activated for the entire TYPO3 installation, also if you have more than one
>> domain..
>> Using the new method (static/constants.txt / static/setup.txt) You'll
>> manually have to include the TS in the template. That way you can have
>> different setups for different domains om the same site..
>> --
>> Peter Klein /Umloud Untd
>> [/quote]
>> So now I think there is a setting for this somewhere. I may have
>> overlooked it in kickstarter.
>> Does anyone know where i can find that setting or wich file?
>> Kind regards
>> Leen

More information about the TYPO3-english mailing list