[TYPO3-dev] conf variables?

JoH asenau info at cybercraft.de
Thu Dec 21 13:58:16 CET 2006


>> function main($content,$conf) {
>>   $this->conf = $conf;
>> }
>>
>> If it isn't there it might be in the parent class.
>>
>> Masi
>
> There is, but no $this->conf["orderEmail_htmlmail"].

Of course not, since $conf is the container for the TypoScript Parameters
handed over to the function.

If the TypoScript Setup is something like:

plugin.whatever = USER
plugin.whatever {
    userFunc = whatever
    parameter1 = 1
    parameter2 = 2
}

You will get these values by using

$conf['parameter1']
$conf['parameter2']

in your function, provided that the function is setup like this:

function main($content,$conf)

So if there is a check for
$this->conf["orderEmail_htmlmail"]
you simply have to add something like

plugin.whatever {
    orderEmail_htmlmail = 1
}

to your TS setup.
There might be an existing section plugin.whatever, so be sure to put it
there.

HTH

Joey

-- 
Wenn man keine Ahnung hat: Einfach mal Fresse halten!
(If you have no clues: simply shut your knob sometimes!)
Dieter Nuhr, German comedian
openBC/Xing: http://www.cybercraft.de
T3 cookbook: http://www.typo3experts.com






More information about the TYPO3-dev mailing list