如题目中描述
光阴似箭催人老,日月如移越少年。
You don’t need to raise your hand to ask these questions...
http://www.open-open.com/lib/view/open1463878352785.html
If it is servlet的话,那简简单单一个filter, it can be done, and someone has already done it, just use it: cors-filter.
servlet
filter
If your problem is that you don’t understand cross-domain, then you have to read: Building public APIs and CORS
public class CorsConfigurerAdapter extends WebMvcConfigurerAdapter{ @Override public void addCorsMappings(CorsRegistry registry) { registry.addMapping("/api/*").allowedOrigins("*"); } }
You don’t need to raise your hand to ask these questions...
http://www.open-open.com/lib/view/open1463878352785.html
If it is
servlet
的话,那简简单单一个filter
, it can be done, and someone has already done it, just use it: cors-filter.If your problem is that you don’t understand cross-domain, then you have to read: Building public APIs and CORS