What is the .htaccess file I should use for eZ Publish?

Our default .htaccess is this one. You can use it for any eZ Publish version.

# Protect files and directories from prying eyes.
<Files ~ "(\.(ini\.append\.php|ini\.append|pl|sh|sql)|bin|cronjobs|update)$">
  Order deny,allow
  Deny from all
</Files>
#Set the timezone
SetEnv TZ Europe/Berlin
#Other Locations see ref http://de2.php.net/manual/en/timezones.php
#SetEnv TZ Europe/London
#SetEnv TZ America/New_York
#SetEnv TZ America/Los_Angeles
#SetEnv TZ Etc/GMT+1
#SetEnv TZ UTC

# Set some options.
Options -Indexes 
Options +FollowSymLinks

# Set the default handler.
DirectoryIndex index.php

# Override PHP settings.
<IfModule mod_php5.c>
  php_value magic_quotes_gpc                0
  php_value register_globals                0
  php_value session.auto_start              0
</IfModule>

<IfModule mod_php4.c>
  php_value magic_quotes_gpc                0
  php_value register_globals                0
  php_value session.auto_start              0
</IfModule>

<IfModule sapi_apache2.c>
  php_value magic_quotes_gpc                0
  php_value register_globals                0
  php_value session.auto_start              0
</IfModule>

<IfModule mod_deflate.c>
 SetOutputFilter DEFLATE
 AddType text/css .css
 AddType text/javascript .js
 AddType text/xml .xml
 AddType text/html .htm

 AddOutputFilterByType DEFLATE text/*
 AddOutputFilterByType DEFLATE application/ms* application/vnd* application/postscript
 AddOutputFilterByType DEFLATE application/xml
 AddOutputFilterByType DEFLATE application/xhtml+xml
 AddOutputFilterByType DEFLATE application/rss+xml
 AddOutputFilterByType DEFLATE application/javascript
 AddOutputFilterByType DEFLATE application/x-javascript
</IfModule>

<IfModule mod_expires.c>              
     FileETag none
     ExpiresActive On        
     ExpiresDefault "access plus 1 day"
     ExpiresByType text/css "access plus 1 month"        
     ExpiresByType text/javascript "access plus 1 month"        
     ExpiresByType image/gif "access plus 1 month"      
     ExpiresByType image/jpg "access plus 1 month"
     ExpiresByType image/jpeg "access plus 1 month"
     ExpiresByType image/png "access plus 1 month"
</IfModule>

# Various rewrite rules.
<IfModule mod_rewrite.c>
RewriteEngine On

RewriteRule ^plesk-stat/webstat(.*) %{DOCUMENT_ROOT}/../statistics/webstat$1 [L]
RewriteRule ^plesk-stat(.*) %{DOCUMENT_ROOT}/../statistics$1 [L]
RewriteRule ^webstat-ssl(.*) %{DOCUMENT_ROOT}/../statistics/webstat-ssl$1 [L]
RewriteRule ^webstat(.*) %{DOCUMENT_ROOT}/../statistics/webstat$1 [L]
RewriteRule ^anon_ftpstat(.*) %{DOCUMENT_ROOT}/../statistics/anon_ftpstat$1 [L]
RewriteRule ^ftpstat(.*) %{DOCUMENT_ROOT}/../statistics/ftpstat$1 [L]
RewriteRule ^error_docs(.*) %{DOCUMENT_ROOT}/../error_docs$1 [L]

#The Mainanace swtich... Enter you IP and only you will see your page... 
#RewriteCond %{REMOTE_ADDR} !^81\.14\.224\.000$
#RewriteCond %{REQUEST_URI} !^/sorry.html$
#RewriteRule (.*) /sorry.html [R,L]
#RewriteCond %{REQUEST_URI} ^/sorry.html$
#RewriteRule .* - [L]

#Clustered setup switch
#RewriteCond %{DOCUMENT_ROOT}%{REQUEST_URI} !-f
#RewriteRule !index_cluster.php - [C]
#RewriteRule ^var/([^/]+/)?storage/images(-versioned)?/.* index_cluster.php

RewriteCond %{HTTP_HOST} ^webdav\..*
RewriteRule ^(.*) webdav.php [L]

RewriteCond %{HTTP_HOST} ^soap\..*
RewriteRule ^(.*) soap.php [L]

#SEO tweak. Redirect all domains except for the main domain 
#RewriteCond %{HTTP_HOST} !^www\..*$
#RewriteRule ^(.*)$ http://www.%{HTTP_HOST}/$1 [L,R=301]

#eZ Publish POP up debug enable if needed
#RewriteRule ^(var/cache|var/[^/]+/)cache/debug.html.* - [L]

RewriteRule ^(.*)favicon\.ico - [L]
RewriteRule ^robots\.txt - [L]
Rewriterule ^var/[^/]+/storage/(images|images-versioned|sitemap)/.* - [L]
RewriteRule ^(var/cache/|var/[^/]+/cache/)(texttoimage|public)/.* - [L]
Rewriterule ^var/storage/packages/.* - [L]
Rewriterule ^design/[^/]+/(stylesheets|images|javascripts?|flash)/.* - [L]
Rewriterule ^share/icons/.* - [L]
Rewriterule ^extension/[^/]+/design/[^/]+/(stylesheets|images|lib|javascripts?|flash)/.* - [L]
RewriteRule ^(index_treemenu.php|content/treemenu/?)$ index_treemenu.php [L]
RewriteRule ^var/[^/]+/cache/(stylesheets|images|javascripts?)/.* - [L]
RewriteRule ezjscore/call/? index_ajax.php
RewriteRule ^index_ajax\.php - [L]

RewriteRule !index_cluster.php - [C]
RewriteRule !index.php - [C]
RewriteRule .* index.php [L]
</IfModule>