mojoPortal Tips: Customizing Your 404 Page
Written by Carole Bennett Wednesday, 11 January 2012
mojoPortal has a “page not found” feature, but many experts recommend using a custom 404 page to improve your site usage. Some ideas for customizing your 404 page:
1) Add links to your most visited site areas, like “Most Popular Articles”, “Frequently Asked Questions”, “Our Products”, or any other information that’s frequently relevant to your customers.
2) Additional contact information: sure, you’ve probably got a great big “Contact Us” link on your menu already, but it never hurts to give your site visitors an extra hand by providing a prompt for contact info.
3) Links to your social media presence, such as your Facebook, Twitter, Google +, and/or LinkedIn pages.
It’s often also recommended to add a bit of humor to the 404 page, via text or graphic – there’s a fine line on this, so work with your content specialist/graphic artist to make sure it’s not demeaning or insulting to would-be site visitors.
Actually implementing a custom 404 page in mojoPortal is fairly simple; the following directions will presume that you’re using Visual Studio for the project.
1) In the “Web” project, locate the file PageNotFound.aspx
2) Copy the file, and rename it as something like “404.aspx”, or whatever equivalent naming convention works for you.
3) Include any edits and additions, as mentioned above, and save the file.
4) Test your changes, to ensure that the file works appropriately in mojoPortal.
5) Open the web.config or user.config, and add this line:
<add key="Custom404Page" value="/404.aspx" />
You now have a custom 404 page for your mojoPortal implementation – congrats!