Welcome Guest, Not a member yet? Register   Sign In
CORS diference between 4.0.4 and 4.1.18
#1

(This post was last modified: 01-28-2022, 02:27 AM by aparedesv.)

Hi,
I have a cors filter in production API developed with the version 4.0.4 and works perfect; now, I clone the same repo in local envirorment and run composer install (with 4.1.18 CI version) and cors filter doesn't work!

my cors filters is:
header('Access-Control-Allow-Origin: *');
        header("Access-Control-Allow-Headers: X-API-KEY, Origin, X-Requested-With, Content-Type, Authorization, Accept, Access-Control-Request-Method");
        header("Access-Control-Allow-Methods: GET, POST, OPTIONS, PUT, DELETE");
        header("Allow: GET, POST, OPTIONS, PUT, DELETE");
       
        $method = $_SERVER['REQUEST_METHOD'];
        if($method == "OPTIONS")
        {
            die();
        }

any idea? thank's!
Reply




Theme © iAndrew 2016 - Forum software by © MyBB