Welcome, Guest ( Customer Panel | Login )




 All Forums
 VPCart Forum
 VP-Cart 8.0 Hint''s and Tips
 Custom 404 Redirect
 New Topic  Reply to Topic
 Printer Friendly
Author Previous Topic Topic Next Topic  

swampthink
VP-CART New User

106 Posts

Posted - August 22 2016 :  07:41:49  Show Profile  Reply with Quote
hi folks, whether the error 404 can be redirected to the new page as notfound.html?

appreciate the help.

ryo_best
VP-CART New User

90 Posts

Posted - August 22 2016 :  08:49:11  Show Profile  Reply with Quote
hi swampthink,

I think you can redirect 404 error to any page that you want, you just need to modify your web.confg, below are the example :

<system.webServer>
<httpErrors>
<remove statusCode="401" subStatusCode="-1" />
<remove statusCode="403" subStatusCode="-1" />
<remove statusCode="404" subStatusCode="-1" />
<remove statusCode="500" subStatusCode="-1" />
<! full url when responsemode is Redirect -->
<error statusCode="401" path="http://foo.com/default.htm" responseMode="Redirect" />
<!-- local relative path when responsemode is ExecuteURL -->
<error statusCode="403" path="~/404error.aspx" responseMode="ExecuteURL" />
<error statusCode="404" path="~/404error.aspx" responseMode="ExecuteURL" />
<error statusCode="500" path="~/404error.aspx" responseMode="ExecuteURL" />
</httpErrors>
<modules runAllManagedModulesForAllRequests="true"/>
</system.webServer>

Hope this helps

cheers
Go to Top of Page

serjtankian
VP-CART Super User

Armenia
378 Posts

Posted - September 08 2016 :  06:28:00  Show Profile  Visit serjtankian's Homepage  Reply with Quote
this what i did with my website

<httpErrors errorMode="Custom">
<remove statusCode="404" subStatusCode="-1" />
<error statusCode="404" prefixLanguageFilePath="" path="/default.asp" responseMode="ExecuteURL" />
</httpErrors>

almost the same but i prefer to redirect 404 to homepage. i read some articles said that its possible to redirect to main category of the product, but still cannot find the best way to do this




*peace - serj*
Go to Top of Page

swampthink
VP-CART New User

106 Posts

Posted - September 14 2016 :  07:11:55  Show Profile  Reply with Quote
hi guys,

thank you for your reply. I have tried both of script and it works

Thanks
Go to Top of Page

danielrichardson
VP-CART Super User

Australia
276 Posts

Posted - September 22 2016 :  11:18:44  Show Profile  Reply with Quote
this is a great guide. thanks
Go to Top of Page

squirrel
VP-CART New User

USA
73 Posts

Posted - October 03 2016 :  01:59:25  Show Profile  Reply with Quote
@ryo_best and @serjtankian

Thanks for posting this.


@swampthink

Glad to know all is well now :)

Thank you.

Best Regards,
Daniel

Be Happy Always
Go to Top of Page
  Previous Topic Topic Next Topic  
 New Topic  Reply to Topic
 Printer Friendly
Jump To:
Snitz Forums 2000
0 Item(s)
$0.00