简体   繁体   中英

Laravel 5.2 - issue with webservices

Recently I am facing one issue with laravel 5.2 Actually, my project is setup on shared hosting server, I am using larval 5.2 for web services but I can't able to pass token with a header, the same code is working fine with 4.2 And the same code is working fine on any dedicated server, From my first R&D I found that I can't able to pass information in the header if my SERVER ["HTTP_CONNECTION"] is 'Off' once I change it to KeepAlive On everything is working good. Can anyone help me on this. ?

Finally i found solution of my problem :) Just use below code in your htaccess file

RewriteEngine On
RewriteCond %{HTTP:Authorization} .
RewriteRule .* - [E=HTTP_AUTHORIZATION:%{HTTP:Authorization}]

It's Done

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM