jQuery Form Observe
- 授权协议: 未知
- 开发语言:
- 操作系统: 未知
- 软件首页: http://plugins.jquery.com/project/form-observe
软件介绍
Overview
This plugin observes values of form elements.
When end-user changes any values of input elements, observer shows which values were changed. And observer also alerts to users when they try to move out from the page before submitting changes.
Usage
You can add FormObserve plugin onto any form element.
$(document).ready(function(){
$('#MyForm').FormObserve();
});
<form id="MyForm">
<input type="text" value="here's default value" />
<input type="submit" value="save" />
</form>If you want to show users the changes, you can add the definition of class 'changed'.
<style>
.changed {
background-color: red;
}
</style>After changes have been completed (might be 'onsubmit', 'ajax complete' and so on), you should call FormObserve_save() method.
$('#MyForm').submit(function(){
if(validation=='ok'){
$(this).FormObserve_save();
}
});Options
changeClass
You can change the class name of changed input-elements.
$(document).ready(function(){
$('#MyForm').FormObserve({changeClass: "alert-color");
});Default value is 'changed'.
msg
You can set the alert message.
Default value is "Unsaved changes will be lost.\nReally continue?"
Tips
You can call FormObserve_save() method to each elements.
$('#ajax-button').click(function(){
// after saving on server
$(this).FormObserve_save();
});This plugin is very handy using with jGlycy.
<form jg="FormObserve">
<input type="text" value="here's default value" />
<input type="submit" value="save" />
</form>Spring Boot实战
[美]克雷格·沃斯 / 丁雪丰 / 人民邮电出版社 / 2016-9 / 59.00元
本书以Spring应用程序开发为中心,全面讲解如何运用Spring Boot提高效率,使应用程序的开发和管理更加轻松有趣。作者行文亲切流畅,以大量示例讲解了Spring Boot在各类情境中的应用,内容涵盖起步依赖、Spring Boot CLI、Groovy、Grails、Actuator。对于Spring Boot开发应用中较为繁琐的内容,附录奉上整理完毕的表格,一目了然,方便读者查阅。一起来看看 《Spring Boot实战》 这本书的介绍吧!
