{"id":635,"date":"2010-10-20T11:15:40","date_gmt":"2010-10-20T03:15:40","guid":{"rendered":""},"modified":"2014-03-11T22:34:05","modified_gmt":"2014-03-11T14:34:05","slug":"6byte%e7%9a%84%e5%88%a4%e6%96%adie%e4%b8%8e%e9%9d%9eie%e7%9a%84%e6%96%b9%e6%b3%95","status":"publish","type":"post","link":"http:\/\/www.xiaoyebailong.com\/index.php\/2010\/10\/20\/635.htm","title":{"rendered":"6byte\u7684\u5224\u65adie\u4e0e\u975eie\u7684\u65b9\u6cd5"},"content":{"rendered":"<p>&lt;script&gt;<\/p>\n<p><span style=\"color: #000000\">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; if(!+[1,])alert(&quot;\u8fd9\u662fie\u6d4f\u89c8\u5668&quot;);<\/span><\/p>\n<p><span style=\"color: #000000\">&nbsp;\u3000\u3000&nbsp;else&nbsp;&nbsp;alert(&quot;\u8fd9\u4e0d\u662fie\u6d4f\u89c8\u5668&quot;);&nbsp;&nbsp;<\/span><\/p>\n<p><span style=\"color: #000000\">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;&lt;\/script&gt;<\/span><\/p>\n<p><span style=\"color: #000000\">&nbsp;<\/span><\/p>\n<p><span style=\"color: #000000\">\u3000\u3000\u5176\u5b9e\u6709\u5f88\u591a\u5224\u65ad\u7684\u65b9\u6cd5\uff0c\u5927\u90fd\u662f\u6839\u636e\u6d4f\u89c8\u5668\u7684\u7279\u6027\u6765\u7684\u3002<\/span><\/p>\n<p><span style=\"color: #000000\">\u3000\u3000\u6bd4\u5982\u5e93prototype\u7684\u65b9\u6cd5\u662f\uff1a!!(window.attachEvent &amp;&amp; navigator.userAgent.indexOf(&#8216;Opera&#8217;) === -1)&nbsp; \u3002\u5c31\u662f\u6839\u636eie\u652f\u6301window.attachEvent\u6dfb\u52a0\u4fa6\u542c\u4e8b\u4ef6\uff0c\u975eie\u7528window.addEventListener\u6dfb\u52a0\u4fa6\u542c\u4e8b\u4ef6\u6765\u5224\u65ad\u7684\u3002navigator.userAgent.indexOf(&#8216;Opera&#8217;) === -1\u662f\u56e0\u4e3aopara\u6d4f\u89c8\u5668\u80fd\u4f2a\u88c5\u6210ie.\u5982\u679c!!(window.attachEvent )\u4e3a\u771f\uff0c\u5c31\u662fie\uff1b\u53cd\u4e4b\uff0c\u5982\u679c!window.addEventListener\u4e3a\u771f\uff0c\u4e5f\u53ef\u4ee5\u5224\u65ad\u4e3aie.<\/span><\/p>\n<p><span style=\"color: #000000\">\u3000\u3000Ext\u4f7f\u7528\u7684\u662f!&quot;1&quot;[0],\u4ed6\u5229\u7528IE\u65e0\u6cd5\u4f7f\u7528\u6570\u7ec4\u4e0b\u6807\u8bbf\u95ee\u5b57\u7b26\u4e32\u7684\u7279\u6027\u6765\u5224\u65ad\u3002\u5728ie8\u4e0b\u597d\u50cf\u6709\u95ee\u9898\u3002<\/span><\/p>\n<p><span style=\"color: #000000\">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; \u5728!+[1,]\u8fd8\u672a\u88ab\u53d1\u73b0\u524d\uff0c\u5224\u65adie\u6700\u77ed\u7684\u8868\u8fbe\u5f0f\u662f&nbsp; !+&quot;\\v1&quot;.\u5b83\u5229\u7528\u7684\u662fie\u4e0d\u652f\u6301\u5782\u76f4\u5236\u8868\u7b26\u7684\u7279\u6027\u3002<\/span><\/p>\n<p><span style=\"color: #000000\">&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;\u4ee5\u524d\u8fd8\u6709\u4e00\u4e2a\u5e38\u7528\u65b9\u6cd5\u662fdocument.all\uff0c\u7531\u4e8eopera\u6d4f\u89c8\u5668\u80fd\u4f2a\u88c5\u6210ie\u3002\u53ef\u4ee5\u8fd9\u6837\u5199:!!(document.all &amp;&amp; navigator.userAgent.indexOf(&#8216;Opera&#8217;) === -1).<\/span><\/p>\n<p><span style=\"color: #000000\">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; \u8fd8\u6709\u5f88\u591a\uff0c\u5148\u8bb0\u8fd9\u51e0\u6761\uff0c\u4fbf\u4e8e\u5de5\u4f5c\u65f6\u67e5\u9605\u3002<\/span><\/p>\n<p><span style=\"color: #000000\">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 1.+[1,]<\/span><\/p>\n<p><span style=\"color: #000000\">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 2.!+&quot;\\v1&quot;<\/span><\/p>\n<p><span style=\"color: #000000\">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 3.!!(window.attachEvent &amp;&amp; navigator.userAgent.indexOf(&#8216;Opera&#8217;) === -1)&nbsp;<\/span><\/p>\n<p><span style=\"color: #000000\">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 4.!!(!window.addEventListener&amp;&amp; navigator.userAgent.indexOf(&#8216;Opera&#8217;) === -1)&nbsp;<\/span><\/p>\n<p><span style=\"color: #000000\">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 5.!!(document.all &amp;&amp; navigator.userAgent.indexOf(&#8216;Opera&#8217;) === -1)<\/span><\/p>\n<div id=\"c_jquery_test\" style=\"display: none\">&nbsp;<\/div>\n<p><script type=\"text\/javascript\">\nif ($ != jQuery) {\n\t$ = jQuery.noConflict();\n}\n<\/script><\/p>\n","protected":false},"excerpt":{"rendered":"<p>&lt;script&gt; &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; if(!+[1,])alert(&quot;\u8fd9\u662fie\u6d4f\u89c8\u5668&quot;); &nbsp;\u3000\u3000&nbsp;else&#038;nbsp&#8230;<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[1],"tags":[],"topic":[],"class_list":["post-635","post","type-post","status-publish","format-standard","hentry","category-technology"],"_links":{"self":[{"href":"http:\/\/www.xiaoyebailong.com\/index.php\/wp-json\/wp\/v2\/posts\/635","targetHints":{"allow":["GET"]}}],"collection":[{"href":"http:\/\/www.xiaoyebailong.com\/index.php\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"http:\/\/www.xiaoyebailong.com\/index.php\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"http:\/\/www.xiaoyebailong.com\/index.php\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"http:\/\/www.xiaoyebailong.com\/index.php\/wp-json\/wp\/v2\/comments?post=635"}],"version-history":[{"count":1,"href":"http:\/\/www.xiaoyebailong.com\/index.php\/wp-json\/wp\/v2\/posts\/635\/revisions"}],"predecessor-version":[{"id":66492,"href":"http:\/\/www.xiaoyebailong.com\/index.php\/wp-json\/wp\/v2\/posts\/635\/revisions\/66492"}],"wp:attachment":[{"href":"http:\/\/www.xiaoyebailong.com\/index.php\/wp-json\/wp\/v2\/media?parent=635"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"http:\/\/www.xiaoyebailong.com\/index.php\/wp-json\/wp\/v2\/categories?post=635"},{"taxonomy":"post_tag","embeddable":true,"href":"http:\/\/www.xiaoyebailong.com\/index.php\/wp-json\/wp\/v2\/tags?post=635"},{"taxonomy":"topic","embeddable":true,"href":"http:\/\/www.xiaoyebailong.com\/index.php\/wp-json\/wp\/v2\/topic?post=635"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}