Friday, 15 April 2011

How to make sure custom js file loaded last in joomla -



How to make sure custom js file loaded last in joomla -

i trying include custom js file joomla site. did edit template's index.php file, , add together <script src='custom.js"></script> right before </head>. when page loaded, there 2 other js files loaded after custom js file. thought inserting script loading line right before closing head tag, js file should lastly 1 load. perchance load 2 js files after js file, , how?

try this,

you can utilize addcustomtag alternative not load js file within head tag should lastly (from calling there load.)

$stylelink .= '<link rel="stylesheet" href="../css/ieonly.css" />'; $document = jfactory::getdocument(); $document->addcustomtag($stylelink);

for more details

hope works..

joomla

No comments:

Post a Comment