Welcom to 评论 - lizhenqiu blog!
#1274
#1275
ed2k://|file|Gospodin.oformitel.1988(ED2000.COM).avi|780392448|16EA7781E1BA6081243A6BAA75089D8E|/
#1276
magnet:?xt=urn:btih:57c8b65e6247db04b927141f358589050203860f&dn=What.Now.Remind.Me.2013.LIMITED.DVDRip.x264-BiPOLAR&tr=http%3A%2F%2Ftracker.trackerfix.com%3A80%2Fannounce&tr=udp%3A%2F%2F9.rarbg.me%3A2710&tr=udp%3A%2F%2F9.rarbg.to%3A2710
magnet:?xt=urn:btih:D2D289DC31A70DF9601E78540F099420F2AFC9F2
magnet:?xt=urn:btih:e8c21d647bafc0bf97f1536b3f12a5c8ace5b39b&dn=Festen%5B1998%5DDVDRip.x264.AC3%5BEng%20Subs%5D.mkv
#1277
var inputBug=function(){ $('input[type="text"]').on('click', function () { var target = this; setTimeout(function(){ target.scrollIntoViewIfNeeded(); },400); }); inputBug();
#1278
<!DOCTYPE html> <html> <head> <title></title> <meta charset="utf-8"> <style type="text/css"> *{ padding: 0; margin:0; } ul{ list-style: none; overflow: hidden; width: 1200px; margin: 0 auto; } li{ width: 300px; height: 300px; float: left; } body{ background-color: #333 } </style> </head> <body> <ul id="canvas"> <li> <canvas class="canvas" width="900" height="900"></canvas> <span>70%</span> </li> <li> <canvas class="canvas" width="900" height="900"></canvas> <span>60%</span> </li> <li> <canvas class="canvas" width="900" height="900"></canvas> <span>30%</span> </li> <li> <canvas class="canvas" width="900" height="900"></canvas> <span>80%</span> </li> </ul> <canvas id="cvs"></canvas> </body> </html> <script type="text/javascript"> window.onload=function(){ var canUl=document.getElementById("canvas"); var li=canUl.getElementsByTagName("li"); var can=canUl.getElementsByTagName("canvas"); var pecent=canUl.getElementsByTagName("span"); var can_arr=[]; function Cavas_pecent(json){ this.w=json.w; this.h=json.h; this.timer=null; this.deg=0; this.new_deg=json.new_deg, this.obj=json.obj; this.color=json.color; this.stroke_color=json.stroke_color; this.pecent_f=json.pecent_f; this.lineWidth=json.lineWidth; this.bg_color=json.bg_color; } Cavas_pecent.prototype.draw = function() { var txt=this.deg+"%"; this.obj.lineCap="round"; this.obj.lineWidth=this.lineWidth; this.obj.strokeStyle = this.stroke_color; this.obj.beginPath(); this.obj.arc(this.w/2,this.h/2,this.w/2-this.lineWidth,0,this.deg/100*Math.PI*2); this.obj.fillStyle="#fff"; this.obj.font="25px Arial"; this.obj.fillText(txt , 150 - this.obj.measureText(txt).width/2 ,150); this.obj.stroke(); } Cavas_pecent.prototype.drawBg = function(){ this.obj.beginPath(); this.obj.strokeStyle=this.bg_color; this.obj.arc(this.w/2,this.h/2,this.w/2-this.lineWidth,0,100*Math.PI*2); this.obj.stroke(); this.obj.save(); return this; } Cavas_pecent.prototype.go_draw = function(){ var _this=this; _this.timer=setInterval(function(){ if(_this.deg==_this.pecent_f){ clearInterval(_this.timer); } else{ _this.deg++; _this.obj.clearRect(0,0,300,300); _this.drawBg().draw() } },30) } for(var i=0;i<can.length;i++) { can_arr[i]=new Cavas_pecent({ w:li[i].offsetWidth, h:li[i].offsetHeight, obj:can[i].getContext("2d"), color:"#a24565", stroke_color:"#a24565", pecent_f:parseInt(pecent[i].innerText), lineWidth:5, bg_color:"#fff" }) can_arr[i].go_draw(); } } </script>
#1279
magnet:?xt=urn:btih:7dab0414a140e688016328b5a9187d9d037f6434&dn=[CK%E7%94%B5%E5%BD%B1%E9%83%A8%E8%90%BDck180.com]%E5%AF%92%E6%9E%9D%E9%9B%80%E9%9D%99.2014.720P.%E4%B8%AD%E5%AD%97
#1280
ed2k://|file|My.way.home.aka.Igy.jottem.Mikl%C3%B3s.Jancs%C3%B3.avi|1275392000|6E24BDDD1ABF4074A0132867CF075C81|/
#1281
#1282
#1283
#1284
#1285
#1286
#1287
#1288
<script> $(document).ready(function () { /* jquery handleError版本兼容 */ jQuery.extend({ handleError: function (s, xhr, status, e) { if (s.error) { s.error.call(s.context || s, xhr, status, e); } if (s.global) { (s.context ? jQuery(s.context) : jQuery.event).trigger("ajaxError", [xhr, s, e]); } }, httpData: function (xhr, type, s) { var ct = xhr.getResponseHeader("content-type"), xml = type == "xml" || !type && ct && ct.indexOf("xml") >= 0, data = xml ? xhr.responseXML : xhr.responseText; if (xml && data.documentElement.tagName == "parsererror") throw "parsererror"; if (s && s.dataFilter) data = s.dataFilter(data, type); if (typeof data === "string") { if (type == "script") jQuery.globalEval(data); if (type == "json") data = window["eval"]("(" + data + ")"); } return data; } }); /* file输入框变化时调用上传图片函数 */ $(".myFile").change(function(){ var objId = $.trim($(this).attr('id')); myUpload(objId); }); /* 上传函数 */ function myUpload(objId) { var _obj = $('#'+objId); var objVal = $.trim(_obj.val()); if(!objVal){ alert('你还未选择图片!'); return false; } $.ajaxFileUpload({ type: "post", url: "upload.do", secureuri:false, fileElementId:objId, dataType: "json", success: function(result) { if (result.code == "1") { alert("上传文件成功!"); } }, complete: function(xmlHttpRequest) { _obj.replaceWith('<input type="file" class="myFile" id="'+objId+'" name="'+objId+'" style="display:none;"/>'); $("#"+objId).on("change", function(){ myUpload(objId); }); }, error: function(data, status, e) { alert("文件上传失败!"); } }); return false; } }); </script>
#1289
<style> .j-sp-ani{width:260px;height:610px;position: absolute;right:131px;top:58px;background: url(https://out.img.pan.lizhenqiu.com/eaeca7a66e50b79338bdedc10bdc45341497326196000) no-repeat; -webkit-animation:run 6.2s steps(8, end) infinite; -moz-animation:run 6.2s steps(8, end) infinite; -ms-animation:run 6.2s steps(8, end) infinite; -o-animation:run 6.2s steps(8, end) infinite; animation:run 6.2s steps(8, end) infinite; } @-webkit-keyframes run { 0% { background-position: 0 0; } 43% { background-position: 0 0; } 50% { background-position: -2080px 0; } 93% { background-position: -2080px 0; } 100% { background-position: -4160px 0; } } @-moz-keyframes run { 0% { background-position: 0 0; } 43% { background-position: 0 0; } 50% { background-position: -2080px 0; } 93% { background-position: -2080px 0; } 100% { background-position: -4160px 0; } } @-ms-keyframes run { 0% { background-position: 0 0; } 43% { background-position: 0 0; } 50% { background-position: -2080px 0; } 93% { background-position: -2080px 0; } 100% { background-position: -4160px 0; } } @-o-keyframes run { 0% { background-position: 0 0; } 43% { background-position: 0 0; } 50% { background-position: -2080px 0; } 93% { background-position: -2080px 0; } 100% { background-position: -4160px 0; } } @keyframes run { 0% { background-position: 0 0; } 43% { background-position: 0 0; } 50% { background-position: -2080px 0; } 93% { background-position: -2080px 0; } 100% { background-position: -4160px 0; } } </style><div class="j-sp-ani"></div>
#1290
<div style="height:30px"></div><script>var el = document.getElementsByTagName('div'); el[0].style.backgroundColor = 'red'; for (var i=0; i< 2000000; i++) { } el[0].style.backgroundColor = 'green';</script>
<div style="height:30px" onclick="rr();"></div><script> function rr(){ var el = document.getElementsByTagName('div'); el[0].style.backgroundColor = 'red'; setTimeout(function(){for (var i=0; i< 2000000; i++) { el[0].style.backgroundColor = 'green'; }},0);} </script>
#1291
#1292
确定要清除编辑框内容吗?
该删除操作将不可恢复。
删除 取消
激活Windows
转到"设置"以激活Windows。
#1274
#1275
ed2k://|file|Gospodin.oformitel.1988(ED2000.COM).avi|780392448|16EA7781E1BA6081243A6BAA75089D8E|/
我最喜欢的电影之一。如诗体般的对白,每一帧都如艺术品般精致,超现实主义的剧情,电子音乐。阴郁又给人以深思。
2.《豹》
一部关于西西里贵族的故事,有家族,有儿女情长,有华丽的舞会,有战争,有家庭矛盾,是一个很好看,很华丽,很美艳的贵族剧。
3.《奥兰多》
你们最喜欢的Tilda。在这里演了一个拥有永生的生命的贵族少年。被伊丽莎白女王喜爱,后来睡了一觉,发现自己变成了女人?????
4.《十诫》 基耶斯洛夫斯基
很多人喜欢基耶斯洛夫斯基,大概都是因为白蓝红三部曲。(此生必看的电影啊,因为看了它而从此爱上东欧)
电影分成十个单元故事,借平凡的生活来阐述对现代版十诫的理解与反思。《十诫》是圣经《出埃及记》里摩西与上帝订下的合约。充满了人性与现实的疑虑。信仰、宗教、道德、婚姻、人情,一幕幕上演。
5.《 吟游诗人》 帕拉杰诺夫的神作。
我当时是在一个咖啡馆看的电影,画质很渣。但是诗电影这个概念,和亚美尼亚文化的那种神秘的美还是令我神往,因为这个片子爱上老帕,也喜欢上了亚美尼亚。
片子出现了唐朝人和拿枪的阿拉伯女人,有点穿越。片子对白很少,几乎是音乐加镜头,但是每一帧都如同油画。推荐。
6.《石榴的颜色》 依旧是老帕。石榴的颜色超长版.Sayat Nova.1969
这个电影给人一种“我完全看不懂但是还是觉得很diao”的感慨。在诗意的捕捉上,这部电影更甚于吟游诗人。
具体大家去看吧。一个刷新三观的好电影。
导演是不是处女座啊。
#1276
迈克尔.哈内克 《爱》
奥地利大导演迈克尔.哈内克是戛纳常客,这部《爱》是他2012年的作品,并最终拿到了金棕榈奖。哈内克擅长描绘人与人间细腻而微妙的关系,对人性有着非常独到的感悟。在《爱》里,哈内克用自己熟悉的方式将一对老夫妻的绝望展现在观众面前,冷酷中夹有温情,震撼后感动长存。
德国
阿奇姆.凡.波瑞斯 《五月的四天》
欧洲人喜欢在电影中反思上世纪那场过去的战争。在这部《五月的四天》里,导演阿奇姆.凡.波瑞斯用自己冷冰冰的叙事手法残酷地通过小男孩彼得的视角把真实的战争展露在了观众们的眼前,让观众自己去体会和解读,而不是用情绪去引导观众,在这点上,本片就已经超过了太多同类电影。
葡萄牙
曼努埃尔.德.奥利维拉 《亚伯拉罕山谷》
曼努埃尔.德.奥利维拉是葡萄牙电影界的传奇宗师。早在1931年他就完成了自己第一部电影的拍摄,导演生涯更是长达六十多年。这部《亚伯拉罕山谷》则是他八十五岁时的作品。
这部电影改编自法国大作家福楼拜的《包法利夫人》,虽说是改编,但其实出了主人公的名字,剧情上奥利维拉做出了大刀阔斧的改动。但他的改动并没有使电影偏离原著的轨道,和其他改编作品相比,倒是这部《亚伯拉罕山谷》似乎更得福楼拜小说的精髓。
若阿金.平托 《然后呢?告诉我》
magnet:?xt=urn:btih:57c8b65e6247db04b927141f358589050203860f&dn=What.Now.Remind.Me.2013.LIMITED.DVDRip.x264-BiPOLAR&tr=http%3A%2F%2Ftracker.trackerfix.com%3A80%2Fannounce&tr=udp%3A%2F%2F9.rarbg.me%3A2710&tr=udp%3A%2F%2F9.rarbg.to%3A2710
这是一部艾滋病人的私人影像日记,在绝望中,男主开始回忆过去,想念自己的朋友,过往的生活,也开始反思自己的人生。有兴趣的朋友可以找来看看,这部电影讲述的不只是艾滋病,更是在讨论生命和死亡的永恒议题。
罗马尼亚
卢西恩.平特莱 《重建》
magnet:?xt=urn:btih:D2D289DC31A70DF9601E78540F099420F2AFC9F2
本片时罗马尼亚国宝级电影大师卢西恩.平特莱成名之作。在罗马尼亚当时的高压政治环境之下,能拍出这样的电影,本身就是件具有革命意义的事情。当最后两个年轻人走向死亡的时候,我仿佛看到平特莱在怒吼。
电影从来都不是一件孤立于社会之外的事情,当国家失去了秩序,电影有责任去为人民发声。
霍拉蒂乌.马拉埃雷 《无声婚礼》
这部2008年的电影讲述了一个残酷而又荒诞的故事。故事发生在1953年的一个罗马尼亚村庄,因为斯大林的去世而导致村子里一场本该进行的婚礼被迫中止,于是他们在夜晚偷偷进行了一场无声的婚礼。至于结局如何我这里不剧透,只能说是非常震撼。
如果连婚礼都无法发声,那这个世界一定离灭亡不远了。
丹麦
托马斯.温特伯格 《家宴》
magnet:?xt=urn:btih:e8c21d647bafc0bf97f1536b3f12a5c8ace5b39b&dn=Festen%5B1998%5DDVDRip.x264.AC3%5BEng%20Subs%5D.mkv
12年一部《狩猎》让丹麦导演托马斯.温特伯格家喻户晓,这里再推荐一部他98年拍摄的电影:《家宴》。
和《狩猎》相同,《家宴》全片都有着一种北欧独特的冷峻气息,作为Dogme95的开山之作,温特伯格大刀阔斧地解开了生活的阴暗面,让人不寒而栗。当然,这部电影强大的剧本也不容忽视。
波兰
多罗塔.肯杰尔扎沃斯卡 《死期将至》
说起波兰电影,人们更多会想到拍摄过《十诫》的基耶斯诺夫斯基,会想到大名鼎鼎的罗曼.波兰斯基。但事实上,波兰女导演多罗塔.肯杰尔扎沃斯卡也应当被我们铭记。
在这部《死期将至》中,多罗塔用她女性特有的细腻将一个老人最后的故事拍的极为纯净,却又让人感伤,美轮美奂,充满了诗情画意。在这部电影里,一切话语都是多余的,每一个镜头都美的无话可说。
比利时
达内兄弟 《一诺千金》
世界影坛上活跃着很多对兄弟,比利时的达内兄弟就是其中一对。拍摄纪录片出身的他们成名于1996年的《一诺千金》,在这部表现父子亲情和比利时移民问题的电影中,达内兄弟运用了大量的手持摄影和长镜头,这样的尝试也让本片的情感表达极具冲击力,在这部电影里,我们能看到一代欧洲导演对艺术的坚持和对欧洲社会未来会往何处去的探讨。
荷兰
保罗.范.霍文 《黑皮书》
说实话这部电影并不冷门,保罗.范.霍文的名气也不需要我赘述,但我非常喜欢这部电影,因为也是小国佳片,就勉强放在这里。
看过《权力的游戏》的朋友对女主卡里斯.范.侯登不会陌生,没错,她就是红发女梅丽珊卓的扮演者,而在这部电影中她要年轻许多,也会更加美丽动人几分。
这部电影的情节可以说是跌宕起伏,反转从头到尾一直出现,剧情很紧凑,可以说是毫无尿点。对于对二战感兴趣的朋友来说,本片更是给出了一个全新的角度。在战争中,其实善恶间的分界并没有我们想象中的那么明显。
土耳其
锡兰 《五月碧云天》
摄影师出身的锡兰如今是土耳其电影的领军人物。他电影里的画面美的让人窒息,简单朴实却直击人心。在这部《五月碧云天》中,锡兰把自己的乡愁带进了电影之中,写实主义的拍摄手法更是让影片中的人物和景色都充满了泥土的芳香,不得不说近年来锡兰在各大电影节受到热捧不无道理。
马来西亚
周青元 《天天好天》
这部是我看过的唯一一部马来西亚电影,很意外的温馨动人,常见的桥段却被导演处理的颇有新意,简单的故事中蕴含着浓浓深情,值得一看。
新西兰
妮琪.卡罗 《鲸骑士》
《鲸骑士》讲述的是毛利人的传奇故事,对于这个题材,妮琪.卡罗处理的非常到位,画面纯净自然,作为一部治愈系的影片,很好看。当然,我印象最深的是年仅十二岁的女主,不但颜值极高,气质上也不似来自人间。
没想到当年的气质小女生,如今变成桀骜不驯的沙蛇!
#1277
var inputBug=function(){ $('input[type="text"]').on('click', function () { var target = this; setTimeout(function(){ target.scrollIntoViewIfNeeded(); },400); }); inputBug();
#1278
<!DOCTYPE html> <html> <head> <title></title> <meta charset="utf-8"> <style type="text/css"> *{ padding: 0; margin:0; } ul{ list-style: none; overflow: hidden; width: 1200px; margin: 0 auto; } li{ width: 300px; height: 300px; float: left; } body{ background-color: #333 } </style> </head> <body> <ul id="canvas"> <li> <canvas class="canvas" width="900" height="900"></canvas> <span>70%</span> </li> <li> <canvas class="canvas" width="900" height="900"></canvas> <span>60%</span> </li> <li> <canvas class="canvas" width="900" height="900"></canvas> <span>30%</span> </li> <li> <canvas class="canvas" width="900" height="900"></canvas> <span>80%</span> </li> </ul> <canvas id="cvs"></canvas> </body> </html> <script type="text/javascript"> window.onload=function(){ var canUl=document.getElementById("canvas"); var li=canUl.getElementsByTagName("li"); var can=canUl.getElementsByTagName("canvas"); var pecent=canUl.getElementsByTagName("span"); var can_arr=[]; function Cavas_pecent(json){ this.w=json.w; this.h=json.h; this.timer=null; this.deg=0; this.new_deg=json.new_deg, this.obj=json.obj; this.color=json.color; this.stroke_color=json.stroke_color; this.pecent_f=json.pecent_f; this.lineWidth=json.lineWidth; this.bg_color=json.bg_color; } Cavas_pecent.prototype.draw = function() { var txt=this.deg+"%"; this.obj.lineCap="round"; this.obj.lineWidth=this.lineWidth; this.obj.strokeStyle = this.stroke_color; this.obj.beginPath(); this.obj.arc(this.w/2,this.h/2,this.w/2-this.lineWidth,0,this.deg/100*Math.PI*2); this.obj.fillStyle="#fff"; this.obj.font="25px Arial"; this.obj.fillText(txt , 150 - this.obj.measureText(txt).width/2 ,150); this.obj.stroke(); } Cavas_pecent.prototype.drawBg = function(){ this.obj.beginPath(); this.obj.strokeStyle=this.bg_color; this.obj.arc(this.w/2,this.h/2,this.w/2-this.lineWidth,0,100*Math.PI*2); this.obj.stroke(); this.obj.save(); return this; } Cavas_pecent.prototype.go_draw = function(){ var _this=this; _this.timer=setInterval(function(){ if(_this.deg==_this.pecent_f){ clearInterval(_this.timer); } else{ _this.deg++; _this.obj.clearRect(0,0,300,300); _this.drawBg().draw() } },30) } for(var i=0;i<can.length;i++) { can_arr[i]=new Cavas_pecent({ w:li[i].offsetWidth, h:li[i].offsetHeight, obj:can[i].getContext("2d"), color:"#a24565", stroke_color:"#a24565", pecent_f:parseInt(pecent[i].innerText), lineWidth:5, bg_color:"#fff" }) can_arr[i].go_draw(); } } </script>
#1279
罗伊.安德森 《生活三部曲》(《二楼传来的歌声》、《你还活着》、《寒枝雀静》
magnet:?xt=urn:btih:7dab0414a140e688016328b5a9187d9d037f6434&dn=[CK%E7%94%B5%E5%BD%B1%E9%83%A8%E8%90%BDck180.com]%E5%AF%92%E6%9E%9D%E9%9B%80%E9%9D%99.2014.720P.%E4%B8%AD%E5%AD%97
瑞典从来都不是电影的荒漠,无论是英格玛.伯格曼还是乔尔恩.陶纳尔,都曾位列这个星球最伟大导演的行列。而如今的瑞典影坛,也有它的代表人物,那就是罗伊.安德森。
罗伊.安德森在三十年的导演生涯中只拍过五部长片,但部部都很精彩。尤其是近年来的《生活三部曲》,罗伊.安德森将自己对生活的感悟倾注在看似荒诞的小故事中,让人笑中带泪,于平淡中体会生活真义。
#1280
米洛克斯.杨索 《红军与白军》
今年的奥斯卡最佳外语片《索尔之子》就来自于匈牙利。其实匈牙利电影从来都是影史中不能略过的一部分,之所以不能略过,很大程度上是因为上世纪六十年代的“匈牙利电影新浪潮”,而这部《红军与白军》的导演杨索就是这次运动的领袖人物之一。
杨索的电影大多表现匈牙利过往的历史,有着鲜明的政治色彩。但其影片中的艺术价值也是极高的,尤其是他对长镜头的运用,已经到了出神入化的地步。
除了这部《红军与白军》,《我的道路》
ed2k://|file|My.way.home.aka.Igy.jottem.Mikl%C3%B3s.Jancs%C3%B3.avi|1275392000|6E24BDDD1ABF4074A0132867CF075C81|/
伊斯特凡.萨博 《信任》
萨博有一部不能算作冷门的电影,那就是拉尔夫.费因斯和蕾切尔.薇姿主演的《阳光情人》,因为那部电影我认识了萨博,于是找来了《信任》,看了之后惊为天人,那种镜头下冷冰冰的感觉实在太过特殊,对战争时期人们心理状况的描写,萨博做到了极致。
#1281
#1282
#1283
#1284
#1285
#1286
#1287
#1288
最近在做一个图片上传的功能,出现提交一次后,file输入框的change事件无法再次触发的bug,就是说提交一次后必须刷新才能再次提交,这就坑了~
于是想办法解决它~
在网上找了一些资料,找到这几种方法:
1、替换掉原来的input框
2、remove原来的input框,然后在添加进新的一样的input框
我测试了之后发现可以用下面的方法解决这个问题:
第一步:上传完成后替换掉原来的input框
第二步:重新绑定onchange事件
<script> $(document).ready(function () { /* jquery handleError版本兼容 */ jQuery.extend({ handleError: function (s, xhr, status, e) { if (s.error) { s.error.call(s.context || s, xhr, status, e); } if (s.global) { (s.context ? jQuery(s.context) : jQuery.event).trigger("ajaxError", [xhr, s, e]); } }, httpData: function (xhr, type, s) { var ct = xhr.getResponseHeader("content-type"), xml = type == "xml" || !type && ct && ct.indexOf("xml") >= 0, data = xml ? xhr.responseXML : xhr.responseText; if (xml && data.documentElement.tagName == "parsererror") throw "parsererror"; if (s && s.dataFilter) data = s.dataFilter(data, type); if (typeof data === "string") { if (type == "script") jQuery.globalEval(data); if (type == "json") data = window["eval"]("(" + data + ")"); } return data; } }); /* file输入框变化时调用上传图片函数 */ $(".myFile").change(function(){ var objId = $.trim($(this).attr('id')); myUpload(objId); }); /* 上传函数 */ function myUpload(objId) { var _obj = $('#'+objId); var objVal = $.trim(_obj.val()); if(!objVal){ alert('你还未选择图片!'); return false; } $.ajaxFileUpload({ type: "post", url: "upload.do", secureuri:false, fileElementId:objId, dataType: "json", success: function(result) { if (result.code == "1") { alert("上传文件成功!"); } }, complete: function(xmlHttpRequest) { _obj.replaceWith('<input type="file" class="myFile" id="'+objId+'" name="'+objId+'" style="display:none;"/>'); $("#"+objId).on("change", function(){ myUpload(objId); }); }, error: function(data, status, e) { alert("文件上传失败!"); } }); return false; } }); </script>
<script> $(document).ready(function () { /* jquery handleError版本兼容 */ jQuery.extend({ handleError: function (s, xhr, status, e) { if (s.error) { s.error.call(s.context || s, xhr, status, e); } if (s.global) { (s.context ? jQuery(s.context) : jQuery.event).trigger("ajaxError", [xhr, s, e]); } }, httpData: function (xhr, type, s) { var ct = xhr.getResponseHeader("content-type"), xml = type == "xml" || !type && ct && ct.indexOf("xml") >= 0, data = xml ? xhr.responseXML : xhr.responseText; if (xml && data.documentElement.tagName == "parsererror") throw "parsererror"; if (s && s.dataFilter) data = s.dataFilter(data, type); if (typeof data === "string") { if (type == "script") jQuery.globalEval(data); if (type == "json") data = window["eval"]("(" + data + ")"); } return data; } }); /* file输入框变化时调用上传图片函数 */ $(".myFile").change(function(){ var objId = $.trim($(this).attr('id')); myUpload(objId); }); /* 上传函数 */ function myUpload(objId) { var _obj = $('#'+objId); var objVal = $.trim(_obj.val()); if(!objVal){ alert('你还未选择图片!'); return false; } $.ajaxFileUpload({ type: "post", url: "upload.do", secureuri:false, fileElementId:objId, dataType: "json", success: function(result) { if (result.code == "1") { alert("上传文件成功!"); } }, complete: function(xmlHttpRequest) { _obj.replaceWith('<input type="file" class="myFile" id="'+objId+'" name="'+objId+'" style="display:none;"/>'); $("#"+objId).on("change", function(){ myUpload(objId); }); }, error: function(data, status, e) { alert("文件上传失败!"); } }); return false; } }); </script>
#1289
<style> .j-sp-ani{width:260px;height:610px;position: absolute;right:131px;top:58px;background: url(https://out.img.pan.lizhenqiu.com/eaeca7a66e50b79338bdedc10bdc45341497326196000) no-repeat; -webkit-animation:run 6.2s steps(8, end) infinite; -moz-animation:run 6.2s steps(8, end) infinite; -ms-animation:run 6.2s steps(8, end) infinite; -o-animation:run 6.2s steps(8, end) infinite; animation:run 6.2s steps(8, end) infinite; } @-webkit-keyframes run { 0% { background-position: 0 0; } 43% { background-position: 0 0; } 50% { background-position: -2080px 0; } 93% { background-position: -2080px 0; } 100% { background-position: -4160px 0; } } @-moz-keyframes run { 0% { background-position: 0 0; } 43% { background-position: 0 0; } 50% { background-position: -2080px 0; } 93% { background-position: -2080px 0; } 100% { background-position: -4160px 0; } } @-ms-keyframes run { 0% { background-position: 0 0; } 43% { background-position: 0 0; } 50% { background-position: -2080px 0; } 93% { background-position: -2080px 0; } 100% { background-position: -4160px 0; } } @-o-keyframes run { 0% { background-position: 0 0; } 43% { background-position: 0 0; } 50% { background-position: -2080px 0; } 93% { background-position: -2080px 0; } 100% { background-position: -4160px 0; } } @keyframes run { 0% { background-position: 0 0; } 43% { background-position: 0 0; } 50% { background-position: -2080px 0; } 93% { background-position: -2080px 0; } 100% { background-position: -4160px 0; } } </style><div class="j-sp-ani"></div>
#1290
如何用单线程来解释?
<div style="height:30px"></div><script>var el = document.getElementsByTagName('div'); el[0].style.backgroundColor = 'red'; for (var i=0; i< 2000000; i++) { } el[0].style.backgroundColor = 'green';</script>
<div style="height:30px" onclick="rr();"></div><script> function rr(){ var el = document.getElementsByTagName('div'); el[0].style.backgroundColor = 'red'; setTimeout(function(){for (var i=0; i< 2000000; i++) { el[0].style.backgroundColor = 'green'; }},0);} </script>
#1291
#1292