Jump to:

4938 Posts in 16827 Topics by 1490 members

Installing SilverStripe

SilverStripe Forums » Installing SilverStripe » Error in .htaccess under assets directory in v2.3.2 RC2

Getting SilverStripe up and running on your computer and on your web server.

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

Page: 1
Go to End
Author Topic: 1675 Views
  • gakenny
    Avatar
    Community Member
    153 Posts

    Error in .htaccess under assets directory in v2.3.2 RC2 Link to this post

    Hello,

    I have been trying out the latest release candidate and I receive the following error in the Apache log files when accessing an image in the assets directory:
    Invalid command 'php_flag', perhaps mis-spelled or defined by a module not included in the server configuration, referer: http://www.domain.com/silverstripe/gallery/

    The code in the .htaccess file reads:
    php_flag engine off

    To overcome this issue, I renamed the .htaccess file. Has anyone else experienced this issue?

    Cheers,

    Gary

  • gakenny
    Avatar
    Community Member
    153 Posts

    Re: Error in .htaccess under assets directory in v2.3.2 RC2 Link to this post

    Hello,

    I believe that our hosting environment uses phpsuexec and this does not allow this override in the .htaccess file and it must occur in php.ini.

    Cheers,

    Gary

  • rbquirke
    Avatar
    Community Member
    70 Posts

    Re: Error in .htaccess under assets directory in v2.3.2 RC2 Link to this post

    It would be ok to comment out this line from the .htaccess

    It is there to prevent php code from being run in the assets folder.

    If your host allows you to set php.ini configs on a per directory basis, then you could create a php.ini for the assets folder, otherwise I would just leave it.

    1675 Views
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.