Welcome to WebmasterWorld Guest from 54.144.243.34

Forum Moderators: open

<script> in another <script>

   
7:49 am on Jan 4, 2005 (gmt 0)

10+ Year Member



Can anybody describe me. Can i attach a <script> file in a <script></script>. I have a towns select and hotel select. But if i attach a whole hotel file. It would be very much information. And i like to dinamycally attach a different files with hotel array to form a hotel select dinamycally.
Is it possible?
2:19 pm on Jan 4, 2005 (gmt 0)

10+ Year Member



document.write("<"+"script type='text/javascript' src='sample.js'><"+"/script>");
5:16 pm on Jan 4, 2005 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Or if you need to contend with Mac IE 4.5,

document.write("<"+"scr"+"ipt type='text/javascript' src='sample.js'><"+"/scr"+"ipt>");

(any occurrence of </script> closes the script in that horrid browser, unfortunately).

10:51 pm on Jan 4, 2005 (gmt 0)

10+ Year Member



Good Mac tip. Thanks choster :)
 

Featured Threads

Hot Threads This Week

Hot Threads This Month