Jump to:

23459 Posts in 18906 Topics by 2877 members

General Questions

SilverStripe Forums » General Questions » application/x-httpd-php?

General questions about getting started with SilverStripe that don't fit in any of the categories above.

Moderators: martimiz, Sean, biapar, Willr, Ingo, swaiba, simon_w

Page: 1
Go to End
Author Topic: 1500 Views
  • jseth
    Community Member
    98 Posts

    application/x-httpd-php? Link to this post

    My network admin is trying to set up virtual hosts for our websites that we host here. The index.php files in my SilverStripe site folders aren't parsing correctly. Through searching, I did find that adding the following:

    AddType application/x-httpd-php .php .htm .html

    was supposed to correct the issue. However, one source said to add it to the .htaccess file - I tried adding it to the .htaccess file in each SilverStripe site folder, but that didn't work. Another source (a post on this site) said to add it to the vhosts.conf file, but that gives me an internal server error. We're restarting apache after each change. The virtual host config works fine for the website that has an index.html, so I'm sure that this is the issue, just not sure what's not quite right. Can anyone shed some light on this for me? Thank you.

  • jseth
    Community Member
    98 Posts

    Re: application/x-httpd-php? Link to this post

    Really, no one has any help for this question? In my error log I get "Request exceeded the limit of 10 internal redirects due to a probable configuration error. User 'LimitInternalRecursion' due to increase the limit if necessary. Use 'LogLevel debug' to get a backtrace."

    From what I can gather, this is a problem with the rewrite in the .htaccess files. When I remove the .htaccess file from the site directory, the page displays with no formatting. When I put the file back, it give me a 500 Internal Server Error - The server encountered an internal error or misconfiguration and was unable to complete your request., which gives the error in the log file.

    It should not be this difficult to get virtual hosting to work. Can anyone help me please!!!!

  • nichess
    Community Member
    3 Posts

    Re: application/x-httpd-php? Link to this post

    Looking for a solution too.

    I found on this site:

    there is a rewrite rule to fix infinite loops:

    RewriteCond %{ENV:REDIRECT_STATUS} 200
    RewriteRule .* - [L]

    But I don't know where to put it, in this part of the .htaccess file:

    <IfModule mod_rewrite.c>
       RewriteEngine On
       RewriteCond %{REQUEST_URI} ^(.*)$
       RewriteCond %{REQUEST_FILENAME} !-f
       RewriteRule .* sapphire/main.php?url=%1&%{QUERY_STRING} [L]

Page: 1
Go to Top

Want to know more about the company that brought you SilverStripe? Then check out SilverStripe.com

Comments on this website? Please give feedback.