Forum Moderators: open

Message Too Old, No Replies

any show/hide scripts not embedded in <head>

         

lli2k5

5:21 am on Sep 7, 2006 (gmt 0)

10+ Year Member



I'm trying to find a show/hide script for DIVs that does not have to be embedded in the header.

Any suggestions?

holyhttp

5:34 am on Sep 7, 2006 (gmt 0)

10+ Year Member



You can use an external javascript file for the script then put
<script language="javascript" src="path/to/your/javascriptfile"></script>
anywhere in your HTML document. It does not have to be on the header.
This will make your code cleaner and easier to manage.

Even inline javascript code can be embedded anywhere in your document boy. Just use
<script>
<!--
your javascrit code; ....
...............
...............
//-->
</script>

lli2k5

5:50 am on Sep 7, 2006 (gmt 0)

10+ Year Member



Thanks a lot.

For some reason, I thought that I couldn't link that specific script externally, but it works now.