随笔分类 - 前端/vue
摘要:1. 子窗口给父窗口元素赋值 function modifyTheme(id){ $("#parent_dom",window.parent.document).attr("value",child_val);//子窗口给父窗口元素赋值 } 2. 子窗口获得父窗口的元素值 var id=$("#theme_id_modify",window.parent.document).val();...
阅读全文
摘要:案例一、 比如:原字符串 现在要删掉冒号,变成123008 就可以先split 这时候分割的每个元素分别是12 30 08,就没有冒号了,然后把这个数组连起来 var ResultString = splitFirst.join('');连接的字符串是空的,啥都没有,也不是空格。这样结果 Resul
阅读全文
摘要://one $('.class').on("click",function(){ alert('one') }); //相当于$('.class').bind("click",function(){……}); //two $(document).on("click",'.class',function(){ alert('two'); }); //相当于$('.class')...
阅读全文
摘要:Js代码 百度云公开下载地址:链接: https://pan.baidu.com/s/1G-96yi4opJYxaEgesh4Dyg 提取码: wh5r Html+Php代码 <volist name="huodong_list" id="v"> <script> $(document).ready
阅读全文
摘要:首先看一下我要解决的问题,第一张图是正常的情况下,第二张图是点击了输入框之后的情况,就是要解决此问题~! 百度了一下解决方法,好像有以下的一些方法: 1. iscroll 2. Jquery Mobile 3. 监听屏幕滚动事件给 #footer 赋值 由于本人新手,第1,2种的方法就没学过,所以暂
阅读全文
摘要:由于$.post() 和 $.get() 默认是 异步请求,如果需要同步请求,则可以进行如下使用:在$.post()前把ajax设置为同步:$.ajaxSettings.async = false;在$.post()后把ajax改回为异步:$.ajaxSettings.async = true;
阅读全文
摘要:$(document).keyup(function(event){ if(event.keyCode ==13){ //是否是回车 var el = event.srcElement || event.target; var input_text = 'knowledge_keywords'; if (el.id == input_te...
阅读全文
摘要:var auth_list = []; $("input[name='auth_list']:checkbox").each(function () { if ($(this).attr("checked")) { auth_list.push($(this).attr('value') ); } ...
阅读全文
摘要:* { filter:progid:DXImageTransform.Microsoft.BasicImage(grayscale=1); -webkit-filter: grayscale(100%); -moz-filter: grayscale(100%); -ms-filter: grayscale(100%); -o-filter: graysc...
阅读全文