Http://localhost/dev/list and Http://127.0.0.1/dev/list
A recent solution to the general general-purpose system of the architecture, encountering the problem of Ajax requests not being executed, was just beginning to think that the spring security permission settings were there.
Ajax Request Call Problem:
Problem Scenario:
The Http://localhost/dev/listUser interface is called in the Http://127.0.0.1/dev/list page, and,
Use Chrome to show cross-domain, response for preflight is invalid redirect
Problem Analysis:
Everyone knows that the default localhost domain name is the corresponding 127.0.0.1,
You can use the ping command to verify that the response to ping 127.0.0.1 and ping localhost is generally 127.0.0.1
This problem does not exist when you switch the access address to http://localhost/dev/list access, and
That is, the browser or Ajax thinks that 127.0.0.1 and localhost are not in the same domain
So dog blood, do not know the Ajax bug or Count Chrome bug,,,
Problem solving:
Use the same IP or the same domain name
With this in mind, I lost 1 days of youth
Ajax Request Call problem