Forum Moderators: open

Message Too Old, No Replies

Including JavaScript

         

Karma

2:01 pm on Jun 12, 2009 (gmt 0)

10+ Year Member



Hi all,

Kinda new to the C#/ASP.NET thing. I have created a fairly simple site, using a master page.

I have a 'contact' page with a few simple inputs (name/email/message etc) and would like to validate the user inputs with Javascript.

How should I import a block of JavaScript just on the contact page?

marcel

5:52 pm on Jun 12, 2009 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



You can import the javascript as you would with any other technology, ie. refernce it within the 'Head'


<script type="text/javascript" src="/scripts/Scripts.js"></script>

But, with asp.net you have validation controls available to you, here is some more info:
[quickstarts.asp.net...]