Friday, September 30, 2005

Sites hosting iTunes Music Videos

The original post has been moved to here.

My apologies to those who linked to this page and then had it disappear since I changed the title. Aparently GoDaddy processes .php pages before mod_rewrite so I can't create RewriteRule(s) on .php files in .htaccess. It's also the reason you don't get a 404 page when the .php script is missing. Very annoying. I'll attempt to ask GoDaddy support about it, but I won't hold my breath that they'll even understand what I'm talking about.

My sugestion for anyone doing php on GoDaddy is to start off from the beginning exposing your .php files as .html or .phtml or what-have-you, always using that as your actual public links and then add something like this to your docroot .htaccess file:

RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} ^(.*)\.html$
RewriteCond %1.php -f
RewriteRule ^(.*)\.html$ http://www.s-seven.net/$1.php [L]


I actually do this, but Blogger requires I put .php if I want .php files generated and since it's creating the links then I have no control over that... but at least you'd get to rewrite the request.