Ok.. I wonder if anyone can shed some light on this.
I have the following code i need to use
document.write('');
document.write('email enquiry');
I understood that if i want to include this directly in the content i should wrap it in {literal} {/literal} - which i did.. but it just displayed the javascript code as content..
I then did the same with global content and user generated tags.. it did the same..
Finally I made it call the code from a .js file i created and all it did was display the code telling it to read the .js file.
Any idea's ?
javascript [Resolved]
javascript [Resolved]
Last edited by cwifi on Sat Jun 09, 2007 4:27 pm, edited 1 time in total.
-
- Support Guru
- Posts: 8169
- Joined: Tue Oct 19, 2004 6:44 pm
- Location: Fernie British Columbia, Canada
Re: javascript
the only time you need to include {literal} scripts is when there are { and/or } characters in your javascript
the rest of the time, the javascript should fit into your page template or page content without any of these.
the rest of the time, the javascript should fit into your page template or page content without any of these.
Follow me on twitter
Please post system information from "Extensions >> System Information" (there is a bbcode option) on all posts asking for assistance.
--------------------
If you can't bother explaining your problem well, you shouldn't expect much in the way of assistance.
Please post system information from "Extensions >> System Information" (there is a bbcode option) on all posts asking for assistance.
--------------------
If you can't bother explaining your problem well, you shouldn't expect much in the way of assistance.
Re: javascript
I see, I removed them but still the code gets dumped straight onto the page as if it was content.. any idea's ?
-
- Support Guru
- Posts: 8169
- Joined: Tue Oct 19, 2004 6:44 pm
- Location: Fernie British Columbia, Canada
Re: javascript
It's Probably a broken tag further above.
Follow me on twitter
Please post system information from "Extensions >> System Information" (there is a bbcode option) on all posts asking for assistance.
--------------------
If you can't bother explaining your problem well, you shouldn't expect much in the way of assistance.
Please post system information from "Extensions >> System Information" (there is a bbcode option) on all posts asking for assistance.
--------------------
If you can't bother explaining your problem well, you shouldn't expect much in the way of assistance.