I’ve been fortunate to work with John Klein and some of the ladies over at KMP Advertising to help them create their new website. They created a beautiful website that I was proud to develop for them.
I built the website with a simple php include template and basic htaccess rewrite for the client pages.
XO Hosting meets Ashton Sanders
We had been planning on switching hosting accounts to my server, but when XO Hosting (there previous hosting provider) promised that it would destroy the email setup, we decided to keep it there. No problem. How bad could it be? If nothing else I will get to write a lengthy XO Hosting Review…
Last night, I started transferring the new website files to the XO Hosting server. I went to test one of the simplest pages on the site, and got an error that said:Â “CGI Scripting not allowed on this server.” Well that stinks. I waited till this morning so I could contact their technical support.
Thankfully, turning CGI Scripting (and PHP) was easy enough to do. Unfortunately, I hadn’t even gotten started on the problems with XO Hosting.
XO Hosting Htaccess
For security reasons, XO Hosting decided to remove most directives from .htaccess. Not only that, ifÂ you do use an improper .htaccess directive on your XO website, your entire website breaks with a 500 Server Error:
500 Internal Server Error
The server encountered an internal error or misconfiguration and was unable to complete your request. Please contact the server administrator www@ and inform them of the time the error occurred, and anything you might have done that may have caused the error.
Reason: Error parsing access file
I especially appreciate the specificness of their “reason.” It makes for very simple debugging.
I found that the only thing I was using .htaccess for (creating pages on the fly) was not allowed, so I broke down and created 50 PHP pages that did the same thing as four lines in my .htaccess had been doing.
And since I mentioned debugging: For some reason, the .htaccess file you upload to an XO server only refreshes every 5 minutes. That’s right, you make a change to your .htaccess file and find out five minutes later that what you did was wrong. You fix the .htaccess file and wait another five minutes to make sure you fixed it.
On top of that, if you have an empty line in your .htaccess file, you get the above-mentioned 500 Internal Server Error (and spend a 1/2 hour trying to debug it).
They also removed all but three Redirect directives. Normally “Redirect 301 <uri> <uri>” works fine in htaccess. NOT FOR XO HOSTING! That is way too sloppy. It has to be:
RedirectPermanent <uri> <uri>
I shouldn’t complain about that point because at least XO Hosting mentioned that in their (5) htaccess help files. Too bad they don’t mention the others I had to figure out with a 5 minute debug lag.
Could XO Hosting Possibly Destroy Htaccess Any More?
I didn’t think so, but I was wrong.
My latest problem is with the recently-mentioned RedirectPermanent directive. Take this test .htaccess page I made:
RedirectPermanent /index.html http://www.kmpadvertising.com/
RedirectPermanent /page.html http://www.kmpadvertising.com/
I’m following all of the rules XO Hosting has written in their help files, and it looks fine on paper. The second redirect works perfectly, but the first redirect redirects to:
This page doesn’t exist, so that redirect actually redirects to a 404 error page… exactly what every webmaster wants. Where could these symbols possibly be coming from? After a little bit of research, “%0D” actually translates into a *return* or *enter* which is the key I have to hit to start a new line in my htaccess file. This also explains why the second redirect works fine. The old site only has 111 .html pages that need to be redirected with .htaccess.
Thank you XO Hosting for replacing all of the simple features that web developers love with complicated and undocumented piles. I’m so glad you offer a “Premium Support Package” so I can pay you more money to teach me how to make htaccess work now that you broke it.
To summarize, as long as you only have one page you will ever need to redirect with your .htaccess file, I highly recommend XO Hosting.
And I thought no one could beat Network Solutions at being a crappy host.