A
A
Anton2018-04-27 17:21:30
htaccess
Anton, 2018-04-27 17:21:30

How to make an exception in a redirect?

RewriteEngine On
RewriteCond %{SERVER_PORT} !^443$
RewriteRule .* https://%{SERVER_NAME}%{REQUEST_URI} [R=301,L]

Now it is.
It is necessary to add an exception here for 1c, which is hollowed out here /bitrix/admin/1c_exchange.php,
it needs to get to http.
I tried everything, nothing.

Answer the question

In order to leave comments, you need to log in

1 answer(s)
A
Alexander, 2018-04-27
@alexr64

RewriteCond %{SERVER_PORT} !^443$ 
RewriteCond %{REQUEST_URI} !^/bitrix/admin/1c_exchange.php*
RewriteRule .* https://%{SERVER_NAME}%{REQUEST_URI} [R=301,L]

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question