Welcome Guest! To enable all features please Login or Register.

Notification

Icon
Error

Custom error messages
mussafj
#1 Posted : Monday, December 11, 2006 4:14:52 PM(UTC)
Groups: Member
Joined: 12/11/2006(UTC)
Posts: 2

I am using the WebGuide application to provide a web interface to my Media Center. I also use a custom host file to prevent ads and "web junk" from displaying in my web browser.

My question is, is there a way to create custom error messages in the Cassini Web Server? Rather than display "Server Error in '/' Application. The resource cannot be found. Description: HTTP 404. The resource you are looking for ... Requested URL: /mac-ad" where the ads would located, I would like to display a simple message such as "This ad has been removed".

I looked in the web.config file and saw something about <error> tags, I'm hoping someone can provide some more information.

Thank you,

Josh
Ultidev Team
#2 Posted : Monday, December 11, 2006 5:19:38 PM(UTC)
Ultidev Team

Groups: Administration
Joined: 11/3/2005(UTC)
Posts: 2,253

Thanks: 28 times
Was thanked: 60 time(s) in 59 post(s)
Hi, Josh.

When you are dealing with IIS and ASP.NET, there are two types of custom errors handlers: first, for errors that happenned in IIS before request reached ASP.NET - for this type of errors you specify custom error pages in IIS management console; and second, for errors that occurred in ASP.NET - for which you can specify handler page in the web.config. For example, if 404 occurred when .ASPX file was requested, it will be handled by ASP.NET and the error handler page defined in web.config, and if the request was for logo.gif and the file was not found, then it will be IIS producing an error page. Since Cassini is much smaller than IIS, server-level custom pages are not implemented - only ASP.NET/web.config pages can be used to customize error screens.

Best regards,
UltiDev Team.
Please donate at http://www.ultidev.com/products/Donate.aspx to help us improve our products.
mussafj
#3 Posted : Tuesday, December 12, 2006 2:19:38 PM(UTC)
Groups: Member
Joined: 12/11/2006(UTC)
Posts: 2

Thank you for the explanation.

Josh
Rss Feed  Atom Feed
Users browsing this topic
Guest
Forum Jump  
You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You can vote in polls in this forum.