473,394 Members | 1,739 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,394 software developers and data experts.

Problem with ASP.NET validation and custom errors on IIS

Hello,

I'm having a pretty strange problem and I'd appreciate if anyone could help
me with it.

I'm having a custom error page on my IIS. Specifically, I've written my own
ASP (classic ASP) error page for "404 Not Found" error. It does some work in
database (via. ADO), and the redirects user to another page. No big deal.
And it worked just fine when all my pages on my website were pure old ASP.

But a few days ago I added another page to my website - an ASP.NET page that
contains a couple of validating controls. When I try to see that page in IE,
I get a javascript "Syntax error". When I debug it, I see that the error is
in file myweb/aspnet_client/system_web/1_1_4322/WebUIValidation.js - and it
seems that the validation script contains HTML and JavaScript from my custom
error page written in ASP!!!

Any ideas? If you need, I can copy/paste some parts of code...

Thanks,
n.
Nov 18 '05 #1
2 1812
It sounds like you don't have the validation JavaScript files available.

I suggest ensuring that
myweb/aspnet_client/system_web/1_1_4322/WebUIValidation.js is actually
present in the root of your website.

If this file was not present you would expect your 404 page to be served
in its place, thus the browser gets html when it's expecting
Javascript.... and errors

Matt
http://www.3internet.co.uk

"ninja_kornjaca" <fr*****************@yahoo.com> wrote in message
news:u5**************@TK2MSFTNGP09.phx.gbl...
Hello,

I'm having a pretty strange problem and I'd appreciate if anyone could help me with it.

I'm having a custom error page on my IIS. Specifically, I've written my own ASP (classic ASP) error page for "404 Not Found" error. It does some work in database (via. ADO), and the redirects user to another page. No big deal. And it worked just fine when all my pages on my website were pure old ASP.
But a few days ago I added another page to my website - an ASP.NET page that contains a couple of validating controls. When I try to see that page in IE, I get a javascript "Syntax error". When I debug it, I see that the error is in file myweb/aspnet_client/system_web/1_1_4322/WebUIValidation.js - and it seems that the validation script contains HTML and JavaScript from my custom error page written in ASP!!!

Any ideas? If you need, I can copy/paste some parts of code...

Thanks,
n.

Nov 18 '05 #2
I agree with Matt. You may also want to check the IIS logs to see what
is happening under the covers. If you are getting an HTTP redirect
(most likely a status of 302), Matt's theory is probably correct. Make
sure that you have the .NET Framework installed on your machine.

Jay Nathan, MCP .NET
Senior Consultant
MARINER
http://www.mariner-usa.com

"matt" <gr************@hitscricket.com> wrote in message news:<bE*********************@wards.force9.net>...
It sounds like you don't have the validation JavaScript files available.

I suggest ensuring that
myweb/aspnet_client/system_web/1_1_4322/WebUIValidation.js is actually
present in the root of your website.

If this file was not present you would expect your 404 page to be served
in its place, thus the browser gets html when it's expecting
Javascript.... and errors

Matt
http://www.3internet.co.uk

"ninja_kornjaca" <fr*****************@yahoo.com> wrote in message
news:u5**************@TK2MSFTNGP09.phx.gbl...
Hello,

I'm having a pretty strange problem and I'd appreciate if anyone could

help
me with it.

I'm having a custom error page on my IIS. Specifically, I've written

my own
ASP (classic ASP) error page for "404 Not Found" error. It does some

work in
database (via. ADO), and the redirects user to another page. No big

deal.
And it worked just fine when all my pages on my website were pure old

ASP.

But a few days ago I added another page to my website - an ASP.NET

page that
contains a couple of validating controls. When I try to see that page

in IE,
I get a javascript "Syntax error". When I debug it, I see that the

error is
in file myweb/aspnet_client/system_web/1_1_4322/WebUIValidation.js -

and it
seems that the validation script contains HTML and JavaScript from my

custom
error page written in ASP!!!

Any ideas? If you need, I can copy/paste some parts of code...

Thanks,
n.

Nov 18 '05 #3

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

Similar topics

9
by: rbronson1976 | last post by:
Hello all, I have a very strange situation -- I have a page that validates (using http://validator.w3.org/) as "XHTML 1.0 Strict" just fine. This page uses this DOCTYPE: <!DOCTYPE html PUBLIC...
2
by: ninja_kornjaca | last post by:
Hello, I'm having a pretty strange problem and I'd appreciate if anyone could help me with it. I'm having a custom error page on my IIS. Specifically, I've written my own ASP (classic ASP)...
2
by: Barbara Alderton | last post by:
I setup some standard Required Field Validation controls and one Custom validation control on an ASP.NET page (within a user control) to validate text entry. I also setup a Summary Control to post...
5
by: Sun Jian | last post by:
Hi, I am trying to customize the asp.net validation to achieve the following: Upon submitting the form, client side validation will run, and it will stop at the first error detected. For...
2
by: TCORDON | last post by:
Is there a way to make the form validation highlight the fields where the errors occur? (change the backcolor of the textboxes)? And second, perform validation without postback and run some...
0
by: A.J. van der Burg | last post by:
Hi all, I have a serious problem with asp.net validation: I developed a custom validation summary control, which will lookup error messages from an external source based on the...
12
by: Dabbler | last post by:
I need to insure that at least one of three phone number fields has a value (requiredfield) but I'm not sure of a way to implement this without server side logic. Is there a way to use the...
3
by: hardieca | last post by:
Hi, I've created an n-tier app where validation rules reside in the business layer. When a webform is saved, a business object examines its state, and if some property is invalid, throws a...
1
by: =?Utf-8?B?ZGlzY2lwbGluZTRldmVyNjY2?= | last post by:
Hi, the CMS out company wrote a few years ago, uses certain attrbutes not included in any HTML validation known. Is there a way to add these custom attributes to HTML validation within VS2005? I...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
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,...
0
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...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...

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.