0

I have simple page written in php which works like single page application, i just use include_once when user want to go to other subpage.Sub pages are pure html but they are saved with extension .php My hosting owner said they are moving to php 5.5, so i have checked on wamp with php 5.5 if page works and it does. But on hosting it cause internal server error, even simple page with php_info() cause it, php versin is set by .httaccess file

 <Files *.php>
 ForceType application/x-httpd-php55
</Files>

Is this something wrong with provider apache configuration? If so what it might be? I'm using standard php.ini generated file.

8
  • Has your hosting provider actually migrated to PHP 5.5 yet? Realistically you shouldn't have to try and force the version in an .htaccess file, they should have it all configured at the top server level - httpd.conf
    – CD001
    Dec 16, 2015 at 9:39
  • its temporary solution for those who didnt change php version yet, but they want to check if page works.
    – whd
    Dec 16, 2015 at 9:42
  • Try AddHandler application/x-httpd-php55 .php .phtml instead? (without the <Files> ... </Files>)
    – CD001
    Dec 16, 2015 at 9:44
  • it cause downloading page instead of interpreting
    – whd
    Dec 16, 2015 at 9:54
  • 1
    It's possible they've not actually upgraded PHP yet on the server then - ForceType just fudges the MIME type, it doesn't actually affect the PHP interpreter I don't think. AddHandler however would invoke the PHP 5.5 interpreter - and if it's not yet installed Apache won't know how to handle the file and you'll get the download prompt.
    – CD001
    Dec 16, 2015 at 10:01

1 Answer 1

0

it turns out that /tmp folder was missing thanks for help

Not the answer you're looking for? Browse other questions tagged or ask your own question.