404 errors, WordPress 2 and password protected directories

Another day, another upgrade to WordPress which breaks my password protected pages with 404 errors I spent months trying to fix before and stupidly did not make a note of the link when I fixed it back in August.

Thankfully others have now found better solutions which should stop WordPress breaking on future upgrades. All you need to do is add the following to your .htaccess file:

ErrorDocument 401 /[path_to_file]/myerror.html
ErrorDocument 403 /[path_to_file]/myerror.html

(noting that the path and file name need to be accuarate and working.. )

solution was found rather ironically on a competing blog publishing tool’s website: http://textpattern.com/faq/173/password-protected-directories-with-htaccess

Riaz Kanani

Founder of Radiate B2B, which helps companies target advertising at specific companies usually as part of an account based marketing programme.

I have spent almost two decades building startups or expanding fast growth companies in a variety of functions - from tech to operations to marketing, with a little corp dev on the side.

Always up for a discussion on building tech businesses and the latest tech trends. Tweet me.