CORS Error (Request header field 0x-version)

I did these to fix the problem

  1. updated the .htaccess file by adding
    Header set Access-Control-Allow-Origin “*” Header set Access-Control-Allow-Headers “0x-version, Content-Type, Authorization, Accept, Origin, X-Requested-With”

  2. Added this snippet at the beginning of my API script:
    header(“Access-Control-Allow-Origin: *”); header(“Access-Control-Allow-Headers: 0x-version, Content-Type, Authorization, Accept, Origin, X-Requested-With”); header(“Access-Control-Allow-Methods: GET, POST, OPTIONS”);

but still have the same issue!