I'm trying to get my personal site set up on bsdwebhosting.net, and I'm having a bit of a problem. I can't seem to get any of my PHP pages to work. Every time I try to view a PHP page, it gives me an Internal Server Error. Plain old HTML and images work fine, but whenever I try to view any page with a .php extension, it gives me an ISE...even if the page doesn't contain any PHP at all. When I run the PHP in my ssh terminal, it spits out the proper code. The site looked fine on my old host, and I haven't changed anything since I moved it. Do any of you have any clues what might be going on? I've run through all the simple solutions I can think of, and I'm stumped. Thanks in advance for any help you can provide.
Originally posted by elsmore1 Possibly they have the server set to run php as cgi and you need to have the she-bang (#!/usr/bin/php) line as the first line of all of your scripts. That is just one of several possibilities.
Do you have access to an error_log and if so, what does it say the error is?
If all else fails, you could always ask your host for help.
Thanks! Adding that she-bang (well, technically it was #!/usr/local/bin/php on this host) at the beginning fixed it. I've never seen a host set up that way for PHP before. Well, they always say you learn something new every day...and lately I've been proving them right every day. I did try to check the error_log file though, but didn't have permission to read it...which makes sense on shared hosting like that. Now it's back to redesigning my site. Thanks again.