White spaces are required between publicId and systemId

前端 未结 5 1966
心在旅途
心在旅途 2020-12-01 10:12

I am trying to make a ajax call to other domain locally from my computer by writing some proxy code in jsp. And this is my jQuery AJAX code that is calling proxy.jsp page. <

5条回答
  •  Happy的楠姐
    2020-12-01 10:51

    The error message is actually correct if not obvious. It says that your DOCTYPE must have a SYSTEM identifier. I assume yours only has a public identifier.

    You'll get the error with (for instance):

    
    

    You won't with:

    
    

    Notice "" at the end in the second one -- that's the system identifier. The error message is confusing: it should say that you need a system identifier, not that you need a space between the publicId and the (non-existent) systemId.

    By the way, an empty system identifier might not be ideal, but it might be enough to get you moving.

提交回复
热议问题