jBox的使用
来源:互联网 发布:淘宝代充为什么便宜 编辑:程序博客网 时间:2024/05/16 15:12
下载地址:https://github.com/StephanWagner/jBox
Notice
var box = new jBox('Notice', { overlay: false, color: "green", attributes: { x: 'left', y: 'top' }, autoClose: false, content: "正在拉取分类……" });
autoClose可以是毫秒时间,false表示显示调用box.close()
Modal
页面
<div id="itemContainer" style="display:none;">弹出层内容</div>
js
productList.editBox = new jBox('Modal', {closeButton: 'title',title: "编辑商品",content: $("#itemContainer"),//页面元素 display:nonedraggable: 'title',//可以拖动width: 750,height: 260,maxWidth: 750,maxheight: 260,closeOnClick: false,ajax: {url: '/admin/getitem',data: {itemid: productId},dataType: "json",type: "POST",reload: 'strict',setContent: false,success: function (response) {if (response && response.item) {productList._initItem(response.item);}else {productList.editBox.close();new jBox('Notice', {overlay: false,color: "black",attributes: {x: 'left',y: 'top'},autoClose: 2000,content: "商品不存在"});}}},onclose: function () {productList.editBox = null;}}).open();
//显示调用open
Confirm
productList.editBox = new jBox('Confirm', {content: $("#itemContainer"),adjustTracker: false,adjustPosition: false,reposition: false,draggable: 'title',width: productList._eidtBoxSize.width,height: productList._eidtBoxSize.height,maxWidth: productList._eidtBoxSize.width,maxheight: productList._eidtBoxSize.height,closeButton: 'title',attributes: { x: 'left',y: 'top'},position: {x: 'center',y: 'center'},title: '编辑商品',closeOnConfirm:false,cancelButton: '关闭',confirmButton: '保存',confirm: function () {productList._saveProduct();},ajax: {url: '/admin/getitem',data: {itemid:productId},dataType: "json",type:"POST",reload: 'strict',setContent: false,success: function (response) {if (response && response.result) {productList._initProductInfo(response.result);}else {productList.editBox.close();new jBox('Notice', {overlay: false,color: "black",attributes: {x: 'left',y: 'top'},autoClose: 3000,content: "服务器忙,请稍后重试"});}},error: function () {productList.editBox.close();new jBox('Notice', {overlay: false,color: "black",attributes: {x: 'left',y: 'top'},autoClose: 3000,content: "服务器忙,请稍后重试"});}}}).open();//open需要显示调用
阅读全文
0 0
- jBox的使用
- JBox的简单使用例子
- JBox的简单使用Demo
- Jbox使用
- jBox使用
- JBox使用详解
- 提示框插件jBox.js的使用示例
- 实用的jbox大全
- JBox
- jBox
- JBOX
- 使用jbox做列表选择
- 关闭 jbox 弹出的层
- jBox 2.3基于jquery的最新多功能对话框插件 常见使用问题解答
- jBox 2.3基于jquery的最新多功能对话框插件 常见使用问题解答
- jquery插件jbox使用iframe关闭问题
- JBox不能样式css样式的问题解决
- $.jBox是一个好的提示效果界面,他的几种使用反式为以下几种,
- 牛客网-考研上机-成绩排序
- 机器学习之PCA
- mysql存储过程查询结果循环遍历 判断 赋值 游标等基本操作
- RQNOJ 252 公司聚会
- jquery的autocomplete
- jBox的使用
- English words page eight
- android 生成开发版SHA1和发布版SHA1
- NGUI减少Drawcall
- 扫雷.c
- 编写Shell脚本的最佳实践
- leetcode389. Find the Difference
- 富途入金步骤记录(个人使用)
- Servlet配置文件