Skip to content

Instantly share code, notes, and snippets.

@wertyoo
Created August 5, 2018 18:06
Show Gist options
  • Save wertyoo/e19aab845143a9cfc7f3bdeaf4742dd2 to your computer and use it in GitHub Desktop.
Save wertyoo/e19aab845143a9cfc7f3bdeaf4742dd2 to your computer and use it in GitHub Desktop.
ht access example
# Reset by DesktopServer
# BEGIN WordPress
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /
RewriteRule ^index\.php$ - [L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . /index.php [L]
</IfModule>
# END WordPress
## EXPIRES CACHING ##
<IfModule mod_expires.c>
ExpiresActive On
ExpiresByType image/jpg "access plus 1 year"
ExpiresByType image/jpeg "access plus 1 year"
ExpiresByType image/gif "access plus 1 year"
ExpiresByType image/png "access plus 1 year"
ExpiresByType text/css "access plus 1 month"
ExpiresByType application/pdf "access plus 1 month"
ExpiresByType text/x-javascript "access plus 1 month"
ExpiresByType image/x-icon "access plus 1 year"
ExpiresDefault "access plus 7 days"
</IfModule>
## EXPIRES CACHING ##
# BEGIN PHP Settings
php_value max_input_vars 3000
php_value upload_max_filesize 128M
php_value post_max_size 128M
php_value memory_limit 128M
php_value max_execution_time 300
php_value max_input_time 300
# END PHP Settings
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment