Incorrect Link Error


In my application I have setup CustomError page for broken and faulty urls. This works fine on my development machine. But when i tries to access a faulty url receives below mentioned error on other environment.

Incorrect link

The link you gave does not work, either because the page it points to has been deleted or moved. If you clicked on a link, please inform the site’s webmaster that the link is faulty.

Please someone help me in this regard.

Jul 06, 2012 10:25

If you are building something from scratch I would suggest Googling episerver dynamic 404 and follow one of the existing solutions others have shared.

If you already have a lot built I assume your custom error page is a EPiServer page.

You need to set it's templates's CurrentPage to a page that exits. Basically:

protected override void OnPreInit(EventArgs e)
            CurrentPage = DataFactory.Instance.GetPage(your error page id from some setting);


Jul 06, 2012 11:19

Hi Johan

I tried adding the below into my error page

 CurrentPage = EPiServer.DataFactory.Instance.GetPage(((PageReference)CurrentPage["CustomErrorPage"]));

but still it gives me the same error when trying to browse from other machines.


Jul 06, 2012 17:51

In EPiServer.config (or web.config if an earlier version of EPiServer), make sure that globalErrorHandling = "Off" in the siteSettings-tag.

Jul 09, 2012 8:50

Hi Erik

Tried changing globalErrorHandling = "Off" but still doesnt work on other environments except development.

Jul 12, 2012 15:11
This thread is locked and should be used for reference only. Please use the Episerver CMS 7 and earlier versions forum to open new discussions.
* You are NOT allowed to include any hyperlinks in the post because your account hasn't associated to your company. User profile should be updated.