asp.net validation

  • Thread starter Thread starter David
  • Start date Start date
D

David

We have a new server running Windows Server 2003. We have copied the
aspnet_client folder to the root folder of the web application.

The problem now is that none of the pages with client side validation
on them, will fire Post Backs to the server, even though all data on
the page is valid.

Removing the aspnet_client folder, from the root enable all the post
backs, but now none of the client side validation fires.

What am I doing wrong?

thanks
David
 
I really try not to be moving around this folder. This folder stays in the
wwwroot folder (I think) and I have had no issues on my development machine.
However, I was hosting a website with a shared host and my client side
validations would not fire, not even on IE, so I know something was up. So,
I just uploaded by webvalidation.js file to my shared host and copied over
the one they had. Everything worked fine after that. I would re-install
asp.net on that box if I were you. This should only take a couple of minutes.
This should not hurt anyting.
 
You have this problem because your old machine has a version of framework
that is different from the one installed on your new machine. It's a known
problem. In general, try not to use client or server side validator, use
exceptions instead. It's more reliable, manageable, controllable, less
complicated, clearer and takes much less code and headaches. One example:
try to disable scripting in your IE to see what will happen with your
carefully crafted client-side validation. It's been discussed thousand times
here, find those posts.
 
I had a similar problem with our transition from 2k to 2k3. It came about
because we copied over a folder called "aspnet_client" in the web root folder
that needed to be generated by the local machine's .NET framework. The most
interesting part was the applications still worked in non-IE browsers.

By deleting that folder (back it up just in case) and then running the
following from the command line, the local machine recreated that folder
according to its own needs (by reregistering/reinstalling the asp.net
portions of IIS):
"aspnet_regiis.exe -i -c"

Hopefully, your's is a similar problem that can be fixed as easily. You may
have to recreate the application name within IIS properties for the ASP.NET
apps.
 
Back
Top