Tag:Cross domain query

  • Ajax cross domain query is perfectly solved through $. Getjson()

    Time:2021-9-16

    reason:Browser security is restricted to prohibit Ajax from obtaining data across domains.resolvent:Data in JSON format can be obtained across domains through $. Getjson () provided by jQuery. Advantages: strong compatibility. Java background code: Copy codeThe code is as follows: protected void doPost(HttpServletRequest req, HttpServletResponse resp) throws ServletException, IOException { String callback =req.getParameter(“callback”);// Custom function name […]