Skip to content
Sri Lanka · Colombo · GlobalMon–Fri, 09:00–18:00 IST
Web Design 1 min read

How to add CSS and Javascript to Your Joomla Extension

When creating a quality Joomla extension you will place your styles and javascript codes on seperate files.

A
Written by
Admin
17 views
Share:
When creating a quality Joomla extension you will place your styles and javascript codes on seperate files. Then here is the way to add those files in to the joomla extension the proper way.
$document = JFactory::getDocument(); $document->addStyleSheet(JURI::root().'mod_name/css/stylesheet.css'); $document->addScript(JURI::root(). 'mod_name/js/script.js');
Share:

Related Articles

Comments (0)

Log in or sign up to leave a comment.

No comments yet. Be the first to share your thoughts!