Advertisement
Guest User

Untitled

a guest
May 3rd, 2012
98
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 2.10 KB | None | 0 0
  1. <ifModule mod_php5.c>
  2. php_flag zlib.output_compression On
  3. php_value zlib.output_compression_level 5
  4.  
  5. php_flag magic_quotes_gpc off
  6. php_flag short_open_tag off
  7. php_flag expose_php off
  8. php_flag display_errors on
  9. php_flag register_globals off
  10. php_flag allow_url_fopen on
  11. php_value file_uploads on
  12. php_value post_max_size 32M
  13. php_value upload_max_filesize 32M
  14. php_value max_execution_time 0
  15. php_value max_input_time -1
  16. php_value memory_limit 128M
  17. php_value default_charset "UTF-8"
  18. php_value session.gc_probability 1
  19. php_value session.gc_divisor 1000
  20. php_value session.gc_maxlifetime 21600
  21. </ifModule>
  22.  
  23. RewriteEngine On
  24.  
  25. IndexIgnore *
  26. Options -Indexes
  27. Options +FollowSymLinks
  28.  
  29. RewriteCond %{REQUEST_METHOD} !^(GET|POST)
  30. RewriteRule .* - [F]
  31.  
  32. RewriteCond %{THE_REQUEST} ^.*/index\.php
  33. RewriteRule .* - [F]
  34.  
  35. RewriteCond %{HTTP_HOST} !^www\. [NC]
  36. RewriteRule ^(.*)$ http://www.%{HTTP_HOST}/$1 [R=301,L]
  37.  
  38. RewriteBase /
  39.  
  40. <IfModule mod_expires.c>
  41. ExpiresActive On
  42. ExpiresDefault "now plus 1 hour"
  43. ExpiresByType text/css "now plus 1 week"
  44. ExpiresByType application/javascript "now plus 1 week"
  45. ExpiresByType application/x-javascript "now plus 1 week"
  46. ExpiresByType image/bmp "now plus 1 year"
  47. ExpiresByType image/gif "now plus 1 year"
  48. ExpiresByType image/jpeg "now plus 1 year"
  49. ExpiresByType image/jp2 "now plus 1 year"
  50. ExpiresByType image/png "now plus 1 year"
  51. ExpiresByType image/x-icon "now plus 1 year"
  52. ExpiresByType image/ico "now plus 1 year"
  53. ExpiresByType image/icon "now plus 1 year"
  54. ExpiresByType application/x-shockwave-flash "now plus 1 year"
  55. ExpiresByType video/mpeg "now plus 1 year"
  56. ExpiresByType video/mp4 "now plus 1 year"
  57. </IfModule>
  58.  
  59. RewriteCond %{REQUEST_FILENAME} !-f
  60. RewriteCond %{REQUEST_FILENAME} !-d
  61. RewriteCond %{REQUEST_URI} !\.(js|css|png|gif|jpg|jpeg|bmp|swf|xsl|doc|pdf|woff|eot|ttf|svg)$
  62. RewriteRule ^(.*)$ index.php?url=$1 [NC,L,QSA]
  63.  
  64. RewriteCond %{REQUEST_FILENAME} -f
  65. RewriteRule ^(core|logs)(.*)$ - [F]
  66.  
  67. RewriteCond %{REQUEST_FILENAME} -f
  68. RewriteCond %{REQUEST_URI} !\.(png|gif|jpg|jpeg|bmp|swf|xsl|doc|pdf|woff|eot|ttf|svg)$ [NC]
  69. RewriteRule ^(images)(.*)$ - [F]
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement