473,732 Members | 2,210 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Client validation not firing



I have an aspx page that was developed initially in Dreamweaver as a
regular html file. I have added a few textboxes and required validators.
The problem is that the client side validation is not firing. Only server
side is working

- I have verified javascript is enabled
- aspnet_client folder is present. Other aspx apps with validation work
fine.
- I can see validation JS code in the html plus the "onsubmit=" if
(!ValidatorOnSu bmit()) return false;" part in the form tag.

- I have "<meta content=JavaScr ipt name=vs_default ClientScript>"

Is there something else I might have missed?
--
John Dalberg
Nov 19 '05 #1
8 5997
Are you sure there are no javascript errors on the page that could be
interfering? Unless you have your IE settings set to display every error,
you would just get an icon in the lower left hand corner.

Also, try creating just the most basic page to reproduce this problem. Try
it in both the apps that work, and the one that doesn't. If the basic page
works, then there is some issue with your app.

"John Dalberg" <jo*****@hotmai l.com> wrote in message
news:xu******** *************** ******@40tude.n et...


I have an aspx page that was developed initially in Dreamweaver as a
regular html file. I have added a few textboxes and required validators.
The problem is that the client side validation is not firing. Only server
side is working

- I have verified javascript is enabled
- aspnet_client folder is present. Other aspx apps with validation work
fine.
- I can see validation JS code in the html plus the "onsubmit=" if
(!ValidatorOnSu bmit()) return false;" part in the form tag.

- I have "<meta content=JavaScr ipt name=vs_default ClientScript>"

Is there something else I might have missed?
--
John Dalberg

Nov 19 '05 #2
Hey John:
Just a thought, are you using something other than IE? client side
validation doesn't work in non-IE browsers...ther e are some free DOM
compatible validation controls out there...

Karl
--
MY ASP.Net tutorials
http://www.openmymind.net/index.aspx - New and Improved (yes, the popup is
annoying)
http://www.openmymind.net/faq.aspx - unofficial newsgroup FAQ (more to
come!)
"John Dalberg" <jo*****@hotmai l.com> wrote in message
news:xu******** *************** ******@40tude.n et...


I have an aspx page that was developed initially in Dreamweaver as a
regular html file. I have added a few textboxes and required validators.
The problem is that the client side validation is not firing. Only server
side is working

- I have verified javascript is enabled
- aspnet_client folder is present. Other aspx apps with validation work
fine.
- I can see validation JS code in the html plus the "onsubmit=" if
(!ValidatorOnSu bmit()) return false;" part in the form tag.

- I have "<meta content=JavaScr ipt name=vs_default ClientScript>"

Is there something else I might have missed?
--
John Dalberg

Nov 19 '05 #3
On Tue, 1 Mar 2005 12:38:34 -0500, Marina wrote:
Are you sure there are no javascript errors on the page that could be
interfering? Unless you have your IE settings set to display every error,
you would just get an icon in the lower left hand corner.

Also, try creating just the most basic page to reproduce this problem. Try
it in both the apps that work, and the one that doesn't. If the basic page
works, then there is some issue with your app.

There are no Javascript errors. I haven't created any of my own and there's
no icon when I submit the form.

A basic app from VS will work. I tool a Dreamweaver html page and I have
been converting the html controls to asp.net. I have been looking in what
VS creates and adding them into the dw one. I even added a dummy textbox
and a validation control from the toolbox just to have vs add the extras if
they are missing. Even the clientscript for that textbox didn't fire.
Enableclientscr ipt is enabled. I am missing something but can't find it.
--
John Dalberg

"John Dalberg" <jo*****@hotmai l.com> wrote in message
news:xu******** *************** ******@40tude.n et...


I have an aspx page that was developed initially in Dreamweaver as a
regular html file. I have added a few textboxes and required validators.
The problem is that the client side validation is not firing. Only server side is working

- I have verified javascript is enabled
- aspnet_client folder is present. Other aspx apps with validation work
fine.
- I can see validation JS code in the html plus the "onsubmit=" if
(!ValidatorOnSu bmit()) return false;" part in the form tag.

- I have "<meta content=JavaScr ipt name=vs_default ClientScript>"

Is there something else I might have missed?
--
John Dalberg


Nov 19 '05 #4
On Tue, 1 Mar 2005 12:40:41 -0500, Karl Seguin wrote:
Hey John:
Just a thought, are you using something other than IE? client side
validation doesn't work in non-IE browsers...ther e are some free DOM
compatible validation controls out there...

Karl


I am using IE. VS doesn't create validation scripts for non IE or at least
non compatible IE browsers. I am seeing the JS validation scripts in the
html output.

I guess my next step is trace the JS.
--
John Dalberg
Nov 19 '05 #5
Does your sample page work in one of the other apps that you say work?

If no javascript is working at all on this page, then the only thing that I
can think of is that IE setting prohibit javascript running in the browser.

"John Dalberg" <jo*****@hotmai l.com> wrote in message
news:1i******** *************** ******@40tude.n et...
On Tue, 1 Mar 2005 12:38:34 -0500, Marina wrote:
Are you sure there are no javascript errors on the page that could be
interfering? Unless you have your IE settings set to display every error,
you would just get an icon in the lower left hand corner.

Also, try creating just the most basic page to reproduce this problem.
Try
it in both the apps that work, and the one that doesn't. If the basic
page
works, then there is some issue with your app.

There are no Javascript errors. I haven't created any of my own and
there's
no icon when I submit the form.

A basic app from VS will work. I tool a Dreamweaver html page and I have
been converting the html controls to asp.net. I have been looking in what
VS creates and adding them into the dw one. I even added a dummy textbox
and a validation control from the toolbox just to have vs add the extras
if
they are missing. Even the clientscript for that textbox didn't fire.
Enableclientscr ipt is enabled. I am missing something but can't find it.
--
John Dalberg

"John Dalberg" <jo*****@hotmai l.com> wrote in message
news:xu******** *************** ******@40tude.n et...


I have an aspx page that was developed initially in Dreamweaver as a
regular html file. I have added a few textboxes and required validators.
The problem is that the client side validation is not firing. Only server side is working

- I have verified javascript is enabled
- aspnet_client folder is present. Other aspx apps with validation work
fine.
- I can see validation JS code in the html plus the "onsubmit=" if
(!ValidatorOnSu bmit()) return false;" part in the form tag.

- I have "<meta content=JavaScr ipt name=vs_default ClientScript>"

Is there something else I might have missed?
--
John Dalberg

Nov 19 '05 #6
Hi John,

You indicated that you confirmed the presence of the \aspnet_client folder.
Its actually a specific subfolder needed in there. Confirm that you have
\aspnet_client\ system_web\[.net version]\
Often users have copied a different version (including a different service
pack) to the production server than matches the version of ASP.NET on that
server.
That's why you should run aspnet_regiis.e xe -c.

Just in case its relevant, see this thread:
http://www.asp.net/Forums/ShowPost.a...&PostID=739537

--- Peter Blum
www.PeterBlum.com
Email: PL****@PeterBlu m.com
Creator of "Profession al Validation And More" at
http://www.peterblum.com/vam/home.aspx

"John Dalberg" <jo*****@hotmai l.com> wrote in message
news:6e******** *************** ******@40tude.n et...
On Tue, 1 Mar 2005 12:40:41 -0500, Karl Seguin wrote:
Hey John:
Just a thought, are you using something other than IE? client side
validation doesn't work in non-IE browsers...ther e are some free DOM
compatible validation controls out there...

Karl


I am using IE. VS doesn't create validation scripts for non IE or at least
non compatible IE browsers. I am seeing the JS validation scripts in the
html output.

I guess my next step is trace the JS.
--
John Dalberg

Nov 19 '05 #7
On Tue, 1 Mar 2005 09:32:10 -0800, John Dalberg wrote:
I have an aspx page that was developed initially in Dreamweaver as a
regular html file. I have added a few textboxes and required validators.
The problem is that the client side validation is not firing. Only server
side is working

- I have verified javascript is enabled
- aspnet_client folder is present. Other aspx apps with validation work
fine.
- I can see validation JS code in the html plus the "onsubmit=" if
(!ValidatorOnSu bmit()) return false;" part in the form tag.

- I have "<meta content=JavaScr ipt name=vs_default ClientScript>"

Is there something else I might have missed?

doh.. I found it! The submit button didn't have an onclick event.
--
John Dalberg
Nov 19 '05 #8
On Tue, 1 Mar 2005 13:50:28 -0500, Peter Blum wrote:
Hi John,

You indicated that you confirmed the presence of the \aspnet_client folder.
Its actually a specific subfolder needed in there. Confirm that you have
\aspnet_client\ system_web\[.net version]\
Often users have copied a different version (including a different service
pack) to the production server than matches the version of ASP.NET on that
server.
That's why you should run aspnet_regiis.e xe -c.


I have several asp.net apps under wwwroot and they have validation controls
in them and they run fine so it can't be the folder. The javascript I saw
running is from the javascript in the form tag. After more investigation
the problem was as small as that the submit button didn't have runat
attribue. It was submitting alright but asp.net wasn't adding the needed
onclick event to run the rest of the JS.
--
John Dalberg
Nov 19 '05 #9

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

3
1410
by: arc | last post by:
I have a server object that performs zipcode validation based on zipcode entered in the web form. Ideally this should work as follows: Once the zip code is entered in the edit box it should validate the entry with this server object before moving to enter state in the next dropdown field. - What is the event by which we can do this for the edit box? (OnBlur doesnt seem to capture the text though it fires up the server object) - This...
4
2373
by: | last post by:
Hello Guys, I am using the validation controls to validate my data. But the problem is "The page is still being posted to server". I want to get rid of the round trips to server. Are there any get arounds for this problem apart from the traditional JavaScript?
14
6308
by: Matt | last post by:
I want to know if ASP.NET Web Forms Validation Controls are Server-Side or Client-Side form validation? Since I think each validator control can select either 1) JavaScript based error dialog or 2) show the error message next to the control. For example, if the text field is empty with RequiredField Validator control, it can show the value in ControlToValidate property in two ways as I mentioned. Please advise. Thanks!
10
4010
by: Tom | last post by:
I have created a new site, using asp.net c#. My pages contain client side validation to validate the users input. On my local machine this works fine, but when I moved my site to the test server, the validation don't want to execute. If I view source on the page I can see the java script is created, but it don't execute. I'm browsing to the site in IE, so it is not a browser problem and the validtation works on other sites on the same...
1
1837
by: Rajani | last post by:
Hi, I have designed a form which process database Insert, edit and Delete(datagrid). I input userid,password and privilege in textboxes which has validation controls to verify data keyed in. And press the button to perform insert operation. Upto here is fine. I want to perform edit or delete operations. I put datagrid for that one.
2
1816
by: Rajani | last post by:
Hi, I have designed a form which process database Insert, edit and Delete(datagrid). I input userid,password and privilege in textboxes which has validation controls to verify data keyed in. And press the button to perform insert operation. Upto here is fine. I want to perform edit or delete operations. I put datagrid for that one.
1
1095
by: tomisarobot | last post by:
Basically a javascript confirm in a CustomValidator based on some business logic. I have a textbox which needs a valid float, so I give it a RequiredFieldValidator and a CompareValidator with a datatype check. The text box also checks some business rules thereafter, and throws up a javascript confirm. If I put 14a in the box, I don't see the confirm dialog If I erase the contents it checks the ReqField and then throws up the
7
22482
controlbox
by: controlbox | last post by:
I have recently inplemented some drop-down lists (combos) on a page where one is dynamically populated according to the selection of another using the microsoft ajax extensions. I had to set AutoPostBack = true, and enable viewstate in order for the serverside events to fire, but once this was done, all seemed well - so far so good... Also, when the page form is submitted, the Javascript validateForm() function is executed to perform...
2
1364
by: DaveyP | last post by:
Ok. I have a page with a textbox which is used to enter numeric data. If data is entered, the code goes to the database and gets the relevant data. If it's left blank, the code assumes that new data is being entered and allocates a number. The problem is that the client side validation (custom validator with Jscript to check for numeric input) on the text box is firing twice.
0
9447
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
9307
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
0
9181
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
8186
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
0
6031
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
4550
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
4809
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
3261
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
3
2180
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.