Today really pit, the eldest brother asked for two days off, came after pointing point, but others said is very in place
Finally the nested small window login registration function, finished, direct adjustment before writing a login registration function, that is, page jump
Not Ajax asynchronous landing
Say let's change to Ajax and return to JSON format. That means using @responsebody.
Well, yes, change it, the page directly with the Freemarker value is also a problem, after all, Ajax background model,put (), the value is not taken out.
After all, the Login registration window is a extracted HTML, the page needs to be directly included in it.
Ok. I feel very comprehensive about myself, and I wrote a dead callback after Ajax success.
Smart too much, boss a look, say you write this is not perfect, also need to optimize under.
What the hell is that?
The callback method was written dead. Need to be flexible.
Well, yes, the final solution is to write a custom attribute in <body> data-seo= "FFF"
After the success inside the var Varf = $ ("body"). Data ("SEO");
Eval (varf+ "()") to make a dynamic call. The default implementation is
window.location.reload () //page Refresh ...
Modifications can be made based on the source code without affecting it. Or just add ... ()
Place
$ ("#id"). Trigger ("click");
How to Trigger V-on:click
$("#id")[0].dispatchEvent(new Event(‘click‘));恩,获取到对象之后触发。
奋斗吧骚年。。。
JS Code Small optimization