modX.regClientScript
Last updated Dec 21st, 2019 | Page history | Improve this page | Report an issue
Support the team building MODX with a monthly donation.
The budget raised through OpenCollective is transparent, including payouts, and any contributor can apply to be paid for their work on MODX.
Backers
Budget
$306 per month—let's make that $500!
Learn moremodX::regClientScript¶
Register JavaScript to be injected before the closing BODY tag.
Syntax¶
API Doc: modX::regClientScript()
void regClientScript (string $src, [boolean $plaintext = false])
Example¶
Add some JS to the end of the page.
$modx->regClientScript('assets/js/footer.js');
See Also¶
- modX
- modX.regClientCSS
- modX.regClientHTMLBlock
- modX.regClientStartupHTMLBlock
- modX.regClientStartupScript
- modX.getRegisteredClientScripts
- modX.getRegisteredClientStartupScripts
Support the team building MODX with a monthly donation.
The budget raised through OpenCollective is transparent, including payouts, and any contributor can apply to be paid for their work on MODX.
Backers
Budget
$306 per month—let's make that $500!
Learn more