### SILVERSTRIPE START ###
<Files *.ss>
	Order deny,allow
	Deny from all
	Allow from 127.0.0.1
</Files>

<Files web.config>
	Order deny,allow
	Deny from all
</Files>

# This denies access to all yml files, since developers might include sensitive
# information in them. See the docs for work-arounds to serve some yaml files
<Files ~ "\.ya?ml$">
	Order allow,deny
	Deny from all
</Files>

ErrorDocument 404 /assets/error-404.html
ErrorDocument 500 /assets/error-500.html

<IfModule mod_expires.c>
  ExpiresActive On
  ExpiresByType text/html "access plus 5 minutes"
  ExpiresByType image/gif "access plus 7 day"
  ExpiresByType image/png "access plus 7 day"
  ExpiresByType image/jpg "access plus 7 day"
  ExpiresByType image/jpeg "access plus 7 day"
  ExpiresByType image/ico "access plus 7 day"
  ExpiresByType text/css "access plus 7 day"
  ExpiresByType text/javascript "access plus 7 day"
  ExpiresByType application/x-javascript "access plus 7 day"
</IfModule>

<IfModule mod_headers.c>
  Header unset ETag
  RequestHeader unset If-Modified-Since
  RequestHeader unset If-None-Match
  FileETag None
</IfModule>

<IfModule mod_alias.c>
	RedirectMatch 403 /silverstripe-cache(/|$)
	RedirectMatch 403 /vendor(/|$)
	RedirectMatch 403 /composer\.(json|lock)
</IfModule>

<IfModule mod_rewrite.c>
	RewriteEngine On
	RewriteBase /
	RewriteCond %{HTTP_HOST} ^1400tower\.com$ [NC]
	RewriteRule ^(.*)/?$ "https://www.1400tower.com/$1" [R=301,L,QSA]

	RewriteCond %{REQUEST_URI} ^(.*)$
	RewriteCond %{REQUEST_FILENAME} !-f
	RewriteCond %{REQUEST_URI} !\.php$
	RewriteRule .* framework/main.php?url=%1 [QSA]

	RewriteCond %{REQUEST_URI} ^(.*)/framework/main.php$
	RewriteCond %{REQUEST_FILENAME} !-f
	RewriteRule . %1/install.php? [R,L]

</IfModule>
### SILVERSTRIPE END

# BEGIN cPanel-generated php ini directives, do not edit
# Manual editing of this file may result in unexpected behavior.
# To make changes to this file, use the cPanel MultiPHP INI Editor (Home >> Software >> MultiPHP INI Editor)
# For more information, read our documentation (https://go.cpanel.net/EA4ModifyINI)
<IfModule php5_module>
   php_flag asp_tags Off
   php_flag display_errors On
   php_value max_execution_time 240
   php_value max_input_time 120
   php_value max_input_vars 1000
   php_value memory_limit 512M
   php_value post_max_size 1008M
   php_value session.gc_maxlifetime 1440
   php_value session.save_path "/var/cpanel/php/sessions/ea-php56"
   php_value upload_max_filesize 1000M
   php_flag zlib.output_compression On
</IfModule>
<IfModule lsapi_module>
   php_flag asp_tags Off
   php_flag display_errors On
   php_value max_execution_time 240
   php_value max_input_time 120
   php_value max_input_vars 1000
   php_value memory_limit 512M
   php_value post_max_size 1008M
   php_value session.gc_maxlifetime 1440
   php_value session.save_path "/var/cpanel/php/sessions/ea-php56"
   php_value upload_max_filesize 1000M
   php_flag zlib.output_compression On
</IfModule>
# END cPanel-generated php ini directives, do not edit
