[TYPO3-v4] Condition for loaded extensions?

Ernesto Baschny [cron IT] ernst at cron-it.de
Tue Feb 22 16:46:28 CET 2011


Ernesto Baschny [cron IT] schrieb am 22.02.2011 16:43:
> Lorenz Ulrich schrieb am 22.02.2011 13:17:
>> Hi everyone
>>
>> I'd like to hear some opinions about introducing a new condition in 4.6.
>>
>> Currently there's no built-in way to find out by condition if an
>> extension is used on a site. To limit the number of requests on a page
>> I'd prefer not to load JavaScript and CSS of an extension that is not
>> used on the current page.
>>
>> Powermail for example brings a userfunc "powermailOnCurrentPage" which
>> does exactly what I like.
>>
>> Wouldn't it be interesting to have a generic condition that can check
>> for content with a specific "list_type"? Are there any other people
>> sharing this need?
> 
> The request for this feature and a lenghty discussion about the best way
> to implement it is already "pending" in the core list.
> 
> Search for RFC #10011. Started out simple but got more and more opinions
> and complexity added, so that at the end there was no output at all from
> the effort. Shame, could have been in 4.5.
> 
> If you want to try again, I suggest to open an new thread for it in the
> core list, maybe even take the last patch from Franz and work upon that.
> Maybe trying to sum up the opinions and what leaded to this particular
> patch and pointing to the previous discussion.

I guess I misread your intension. You want to find out if an "plugin" is
actively being loaded on the current page? That's difficult to do,
because you will only know about it after the rendering is complete (*).
And there is no way to know that at TypoScript parsing and splitting up
time, which is when a condition kicks in.

Cheers,
Ernesto

(*) a plugin can be loaded on a page through tons of different ways, it
doesn't need to specifically be present as a record on the current page:
it might come from the template itself, from a "load records" content
element which loads it from another page, or even added through PHP by
some other extension in some other crazy fashion. You only know that
they were included after rendering of that particular page is finished.


More information about the TYPO3-project-v4 mailing list