Well, almost all is in the question.
From a newly created module, i would like to be able to inject new meta/script tag which will be added later inside the header when rendered.
I'm pretty it should be a method to do this.
Any ideas ?
Well, almost all is in the question.
From a newly created module, i would like to be able to inject new meta/script tag which will be added later inside the header when rendered.
I'm pretty it should be a method to do this.
Any ideas ?
I did this in quiet a naive way: I prepared the page inside joomla administration panel without scripts etc, then, with phpmyadmin I modified the article directly inside the db.
But if I understood your question well you want to modify something that's outside the 'content' part. In that case you could modify the engine part that manages that part of the page and, when a given page is loaded (the article you need to modify meta/script etc...) change those parts
I found the method to do it. It's a part of the JHTML class.
// Add a reference to a javascript file
// The default path is 'media/system/js/'
JHTML::script($filename, $path, $mootools);
// Add a reference to a CSS file
// The default path is 'media/system/css/'
JHTML::stylesheet($filename, $path);
$document =& JFactory::getDocument();
$document->addScript($url);