The Arcive of vBulletin Modifications Site. |
|
Reference a js file in a template Details »»
|
|||||||||||||||||||||||||
How can I call a js file in a template?
Thanks! Show Your Support
|
|||||||||||||||||||||||||
| Comments |
|
#2
|
||||
|
||||
|
The same way you do it in a normal HTML file.
<script language="Javascript" src="yourfilenamehere.js"></script> Put the JS file in your forums directory. |
|
#3
|
|||
|
|||
|
Technically it should now be type="text/javascript" instead of language="Javascript" but the W3C never keeps a standard for more than six months anyway
|
|
#4
|
||||
|
||||
|
Use the one I posted - it's the same format that vB uses to call the vBCode external file vbcode.js, so it should work within vB.
|
![]() |
|
|