Gossamer Forum
Home : General : Internet Technologies :

validation javascript - in header or body - does it matter?

Quote Reply
validation javascript - in header or body - does it matter?
Hi All

I have some validation javascript that I'd like to add to some pages.

I know that it's supposed to go into the head, but could the same validation code be put into the body if that's all I had access to?

In fact, could I put a remote call for the validation code into the body, as well?

Many thanks Smile

------------------------------------------
Quote Reply
Re: [DogTags] validation javascript - in header or body - does it matter? In reply to
Hi,

As long as you have it wrapped with a <script ..> .. </script> tag, then you should be able to use it anywhere on the page (not 100% sure on compatabiliy between browsers though).

e.g;

Code:
<html>
<head>
...
<script>
....
</script>

</head>
<body>
normal content here
</body>
</html>

Code:
<html>
<head>
..
</head>
<body>
<script>
....
</script>

normal content here
</body>
</html>

Hope that helps.

Cheers

Andy (mod)
andy@ultranerds.co.uk
Want to give me something back for my help? Please see my Amazon Wish List
GLinks ULTRA Package | GLinks ULTRA Package PRO
Links SQL Plugins | Website Design and SEO | UltraNerds | ULTRAGLobals Plugin | Pre-Made Template Sets | FREE GLinks Plugins!
Quote Reply
Re: [Andy] validation javascript - in header or body - does it matter? In reply to
Thanks, And Smile

------------------------------------------

Last edited by:

DogTags: May 13, 2005, 3:49 AM