:: Professional ::
 
You are here: Blog
 

Hilbert Solutions, LLC Latest Dotnetnuke Modules...

Advanced News Ticker        Constant Contact Sign Up

 

Blog
Aug28

Written by:slhilbert
8/28/2008 3:18 PM RssIcon

Here is a quick tip to display one of those cool pages to people when they either try to get to a page on your site that doesn't exist or when something happens and an error occurs on your site.

  1. Open up your web.config file
  2. Locate the line that starts wtih
  3. <customErrors
  4. Set the mode equal to "On"
  5. Then create another attribute in the tag labeled "defaultRedirect="URLOfErrorPage"
  6. The tag will end up looking something like this

Note: This only works for pages ending in aspx, for pages ending in something else you will need to either configure IIS or see if your web host provider offers the ability to configure custom error pages.

Or you can check out this great article by SEABlick Consulting regarding 301 redirects which you can easily use to setup 404 redirects http://seablick.com/blog/articletype/articleview/articleid/114/understanding-301-redirects.aspx

2 comment(s) so far...


Re: Dotnetnuke Redirection for non-existing ASPX Pages.

Thanks but if you are hosting multple portals all with 1 web.config, how does that solution work?

By BT on  10/19/2008 8:18 PM

Re: Dotnetnuke Redirection for non-existing ASPX Pages.

You will need to follow the Seablick.com solution I posted for al types of pages.

By Stuart on  10/19/2008 8:23 PM

Your name:
Gravatar Preview
Your email:
(Optional) Email used only to show Gravatar.
Your website:
Title:
Comment:
Security Code
Enter the code shown above in the box below
Add Comment  Cancel 
Search Blog
Blog Archive
Terms Of Use| Privacy Statement Hilbert Solutions, LLC Since 2007