My target is to remove .php extensions from url and create Semantic URL multilingual site. Here is my .htaccess rules:

```
# Turn mod_rewrite on
RewriteEngine On

#Remove .php extensions from files
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{DOCUMENT_ROOT}/$1\.php -f
RewriteRule ^(.+?)/?$ /$1.php [L]

#Create Semantic url
RewriteRule  ^event/([A-Za-z0-9-\+]+)/([A-Za-z0-9-\+]+)/?$  calendar?region=$1&news_id=$2 [L,NC]

#Handle language switch.
RewriteRule ^(ru)/(.*)$  $2?sitelang=2 [L,QSA]
RewriteRule ^(ru)$  $1?sitelang=2 [L,QSA]
RewriteRule ^(en)/(.*)$  $2?sitelang=1 [L,QSA]
RewriteRule ^(en)$  $1?sitelang=1 [L,QSA]
RewriteRule ^(.*)$  $1?sitelang=1 [L,QSA]

#404 Document /404.php
ErrorDocument 404 /404

```

So I have some cases when this rules work but also when does not work. So here are the working ones:

* domain.com/**ru**/event/region/some-event-name
* domain.com/event/region/some-event-name

And the ones wich does not work(when I add something,bold), causes 500 error:

* domain.com/event**s**/region/some-event-name
* domain.com/event**s**/region/some-event-name/
* domain.com/event/region/some-event-name/**something**