[TYPO3] Safely adding JavaScript onload or onresize events in Typo3
Peter Klein
peter at umloud.dk
Sun Jun 18 12:24:18 CEST 2006
Hi Cyprian . I do it like this:
$GLOBALS['TSFE']->additionalHeaderData[$this->extKey] .= '<script
type="text/javascript"
src="'.t3lib_extMgm::siteRelPath($this->extKey).'myJavaScript.js"></script>';
$GLOBALS['TSFE']->JSeventFuncCalls['onload'][$this->extKey] =
'myOnLoadJavaScriptFunc()';
---
Peter Klein / Umloud Untd
"Cyprian Kowalczyk" <cyprian at pi2.pl> wrote in message
news:mailman.1.1150620921.8399.typo3-english at lists.netfielders.de...
> Hello,
>
> I've been wondering if there is any safe way to add JavaScript onload or
> onresize events in Typo3.
> What I mean by 'safe way'.
> So imagine I'd like to add some JS functions to execute on page load, but
> there may be some other functions defined by extensions or templates,
> right?
> So, how to solve it, maybe I missed something.
> Thank you for any hints in advance.
>
> --
>
> regards, Cyprian
> pi2.pl ~ ?^2 design project
More information about the TYPO3-english
mailing list