WebAPI deal with cross-domain issues

  1, according to https://dzone.com/articles/access-control-allow-origin-header-and-the-aspnet article said, the program configured to allow cross-domain request.

                             

       But the request is still wrong.

  2, the following error message:

    Response to preflight request doesn't pass access control check: It does not have HTTP ok status.

  3, the browser tries to request the server interface data

    The following error message:

     

    Solution:

     

    Comment out the above information can be a normal visit.

 

Guess you like

Origin www.cnblogs.com/lyyd/p/11641325.html