Hello,
Is there a way to link to style sheets in modules? As far as I'm aware a link tag has to be put in the head section, but I'm not aware of any way of doing this in modules.
I've seen one module that used link tags within the body, but that's not actually valid XHTML. Link tags are only meant to be in the head section.
So far for the module I'm working on I've done a very crude hack by simply putting the link tag in the site's template, but that's not a particularly desirable way of doing things for obvious reasons.
Using the style attribute isn't practical in this situation.
Thanks,
Mark.
Style sheets in modules
Moderators: tjay, seadap, Rogue4ngel, matthewhayashida
Forum rules
Re: Style sheets in modules
$document = &JFactory::getDocument();
$document->addStyleSheet( $url );
Ian
$document->addStyleSheet( $url );
Ian
Help test my Component XML Generator Tool!
http://extensions.joomla.org/component/option,com_mtree/task,viewlink/link_id,1997/Itemid,35/
All feedback appreciated!
http://extensions.joomla.org/component/option,com_mtree/task,viewlink/link_id,1997/Itemid,35/
All feedback appreciated!
Re: Style sheets in modules
markdarb if I am not mistaken that is code for 1.5. If so, do you know how it is done in 1.1?
Re: Style sheets in modules
No I don't know how to do it in 1.1, but since I'm using 1.5 it doesn't matter terribly. Why? Were you offering to tell me how to do it in 1.1 if I need to know, or trying to find out because you don't know?
Thanks,
Mark.
Thanks,
Mark.
Re: Style sheets in modules
Trying to find out because I don't know myself! I have not used 1.5 yet..