apache - Force the mod_rewrite to pass request parameters when rewriting -


I http http ) to all the web server users. This code is using I:

  RewriteBase / RewriteCond% R {} HTTP_HTTPS} rewrite engine! = Revert Rule ^ (. *) $ Https: //% {SERVER_NAME} / $ 1 [R = 301, L]  

However, I have realized that when user information With the request to http , then this relay rule is executed, then the postal data is lost.

Is there a way to rewrite HTTPS, make sure that all POST data is also sent.

two 307 (temporary) and 308 (Permanent), which you can use for this kind of case. These status codes redirect the code to 302 and 301 , but keep the method ( GET / POST ] up to

RewriteRule ^ (. *) $ Https: //% {SERVER_NAME} / $ 1 [R = 308, L]

However, you should See the answer for the details as long as everything works as expected with the exam 307 .


Comments

Popular posts from this blog

apache - 504 Gateway Time-out The server didn't respond in time. How to fix it? -

c# - .net WebSocket: CloseOutputAsync vs CloseAsync -

c++ - How to properly scale qgroupbox title with stylesheet for high resolution display? -