SpringMVC value processor returns the result of a returned value

 

The processor total is divided into two categories:

One is a return to the page, the processor returns all pages, will refresh the page, the corresponding request should be synchronized request.

One is to return a result, all results returned processor, the requester must need the result value, then you need a way to request a callback function, which is an asynchronous request ajax.

So, in the future development, as long as the return to a page you think of sync, as long as a return value to consider asynchronous.

It returns a value in two ways:

method one

  • Front-end interface

 

 

  • Background code

 

 But the value returned by the above method if the Chinese will be garbled

Then it sets through produces.

 

Second way

  • Front page

  • Background code

 

Guess you like

Origin www.cnblogs.com/kitor/p/10988339.html