Layer For Mobile 之 layer.full()

背景介绍:layer mobile是专门针对手机页面开发的一套框架,具体介绍请看官方文档 http://layer.layui.com/mobile/api.html,因其扩展方法有限,我用到了layer Pc版的layer.full这里做了扩展。

问题:目前layer mobile是2.0版,没有layer.full方法。因为用到做了扩展。

包括两部分,一部分是js,一部分是样式。

js部分

function LayerFull(title, url) {

    layer.open({
type: 1,
btn: ["点击关闭本页面"],
yes: function (index) {
layer.close(index);
},
title: title,
content: "<iframe src=" + url + " width='100%' height='96%'></iframe>",
style: 'position:fixed; left:0; top:0; width:100%; height:96%; border: none;'
}); };

css部分

.layui-m-layercont {
height: 80%;
}
.layui-m-layercont iframe {
border: none;
z-index:;
}
.layui-m-layermain .layui-m-layerchild h3 {
height: 30px;
line-height: 30px;
} /**
iOS兼容iFrame滚动条样式
*/
.layui-m-layercont {
overflow-y: scroll;
-webkit-overflow-scrolling: touch;
width: 100%;
/*height: 330px;*/
} .layui-m-layercont iframe {
width: 100%;
/*height: 80%;*/
}

layer mobile开发layer.full的更多相关文章

  1. jQuery Layer mobile 弹出层

    layer mobile是为移动设备(手机.平板等webkit内核浏览器/webview)量身定做的弹层支撑,采用Native JavaScript编写,完全独立于PC版的layer,您需要按照场景选 ...

  2. layer.js中layer.tips

    <script src="~/Content/js/layer/layer.js"></script> layer.tips('名称不能为空', '#pro ...

  3. (转)经典收藏 50个jQuery Mobile开发技巧集萃

    (原)http://www.cnblogs.com/chu888chu888/archive/2011/11/10/2244181.html 经典收藏 50个jQuery Mobile开发技巧集萃   ...

  4. 18个jQuery Mobile开发贴士和教程

    jQuery Mobile 是 jQuery 在手机上和平板设备上的版本.jQuery Mobile 不仅会给主流移动平台带来jQuery核心库,而且会发布一个完整统一的jQuery移动UI框架.支持 ...

  5. Transport layer and Network layer

    http://stackoverflow.com/questions/13333794/networking-difference-between-transport-layer-and-networ ...

  6. layer mobile 指定URL连接 弹全屏

    var url_a = $("#"+id).attr("alt"); //打开新页面 var pageii = layer.open({ type: 1, bt ...

  7. 经典收藏 50个jQuery Mobile开发技巧集萃

    http://www.cnblogs.com/chu888chu888/archive/2011/11/10/2244181.html 1.Backbone移动实例 这是在Safari中运行的一款Ba ...

  8. jquery mobile开发笔记之Ajax提交数据(转)

    http://my.oschina.net/xiahuawuyu/blog/81763 这两天学习了下,jquery mobile(以下简称jqm)的开发相关的内容.可能之前有过web的开发基础,相对 ...

  9. 关于 layer.mask = label.layer 出现空白情况

    源代码如下: self.numLabel = [[UILabel alloc]initWithFrame:CGRectMake(0, 0, self.view.frame.size.width/3, ...

随机推荐

  1. PHP中file_exists()判断中文文件名无效的解决方法

    php中判断文件是否存在我们会使用file_exists函数或is_file函数,但在使用file_exists时如果你文件名或路径是中文在uft8编码文档时是无效.本文就来解决此问题,下面我们一起来 ...

  2. 字节流之文件输入流FileInputStream

  3. p2148 [SDOI2009]E&D

    传送门 分析 https://www.luogu.org/blog/flashblog/solution-p2148 代码 #include<bits/stdc++.h> using na ...

  4. 写一段php代码,确保报个进程同时写入同一个文件

  5. ShopNc实例化对象

    1.模型 $model_member = Model('member'); 2.接口 require_once BASE_ROOT_PATH.'/member/api/smiMember/action ...

  6. Git安装和常用命令

    Git是目前世界上最先进的分布式版本控制系统!!! Git能自动帮我们记录每次文件的改动,还可以让同事协作编辑. 接下来,简单的介绍下Git的安装和常用命令: Git安装: 1.Windows系统,进 ...

  7. M(必备),R(需求),C(条件),O(可选)

    M:must 必备 R:request 需求 C:condition 条件 O:option 可选 AFL:application file locator 应用文件定位器 PKI:公钥索引 IPK: ...

  8. js实现在表格中删除和添加一行

    <!DOCTYPE html><html> <head> <title> new document </title> <meta ht ...

  9. mac安装nose,command not found:nosetests

    mac通过pip install nose失败,看了一下是权限的问题,重新用sudo pip install nose安装,安装成功. 但是执行nosetests时,提示command not fou ...

  10. MVC全局用户验证之HttpModule

    在请求进入到MVC的处理mcvHandler之前,请求先到达HttpModule,因此可以利用HttpModule做全局的用户验证. HttpModule MVC5之前的版本基于system.web. ...