aboutsummaryrefslogtreecommitdiff
path: root/files/zh-cn/mozilla/firefox/releases/21
diff options
context:
space:
mode:
Diffstat (limited to 'files/zh-cn/mozilla/firefox/releases/21')
-rw-r--r--files/zh-cn/mozilla/firefox/releases/21/site_compatibility/index.html146
1 files changed, 146 insertions, 0 deletions
diff --git a/files/zh-cn/mozilla/firefox/releases/21/site_compatibility/index.html b/files/zh-cn/mozilla/firefox/releases/21/site_compatibility/index.html
new file mode 100644
index 0000000000..ca4ee89c81
--- /dev/null
+++ b/files/zh-cn/mozilla/firefox/releases/21/site_compatibility/index.html
@@ -0,0 +1,146 @@
+---
+title: Firefox 21网站兼容性
+slug: Mozilla/Firefox/Releases/21/Site_compatibility
+translation_of: Mozilla/Firefox/Releases/21/Site_compatibility
+original_slug: Site_Compatibility_for_Firefox_21
+---
+<div>{{FirefoxSidebar}}</div><section id="sect1">
+ <h2 id="CSS">CSS</h2>
+ <section id="sect2">
+ <h3 id="-moz-user-selectnone的表现变得和-moz-user-select-moz-none相同也就是和其他浏览器实现了统一"><code>-moz-user-select:none的表现变得和</code><code>-moz-user-select:-moz-none</code>相同,也就是和其他浏览器实现了统一</h3>
+ <ul>
+ <li><a href="https://bugzilla.mozilla.org/show_bug.cgi?id=816298">Bug 816298 – Change "-moz-user-select:none" to behave like WebKit, IE, and Opera (and "-moz-user-select:-moz-none")</a></li>
+ </ul>
+ <p>Previously, when you set the <code>none</code> keyword to the <a href="/zh-CN/docs/CSS/user-select"><code>-moz-user-select</code></a> property, the text of on the element and sub-elements became unselectable, even if one of those sub-elements had <code>-moz-user-select:text</code>. Starting with Firefox 21, <code>none</code> behaves like <code>-moz-none</code> and other browsers, so selection can be re-enabled on sub-elements using <code>-moz-user-select:text</code>.</p>
+ </section>
+</section>
+<section id="sect15">
+ <h2 id="DOM">DOM</h2>
+ <section id="sect23">
+ <h3 id="删除了对table的cols和layout属性的支持">删除了<code>对table</code>的<code>cols</code>和<code>layout</code>属性的支持</h3>
+ <ul>
+ <li><a href="https://bugzilla.mozilla.org/show_bug.cgi?id=835169">Bug 835169 – Do we need support for the table[cols] attribute?</a></li>
+ <li><a href="https://bugzilla.mozilla.org/show_bug.cgi?id=835439">Bug 835439 – Remove support for the table[layout] attribute</a></li>
+ </ul>
+ <p>Firefox no longer accepts the <code>cols</code> and <code>layout</code> properties on the <a href="/zh-CN/docs/HTML/Element/table"><code>table</code></a> elements. No other browsers support these obscure properties.</p>
+ </section>
+ <section id="sect24">
+ <h3 id="scrollWidth和scrollHeight不再受overflowvisible的影响"><code>scrollWidth</code>和<code>scrollHeight</code>不再受<code>overflow:visible</code>的影响</h3>
+ <ul>
+ <li><a href="https://bugzilla.mozilla.org/show_bug.cgi?id=833542">Bug 833542 – scrollWidth, scrollHeight different when overflow is hidden versus visible</a></li>
+ </ul>
+ <p>The <a href="/zh-CN/docs/DOM/element.scrollWidth"><code>scrollWidth</code></a> and <a href="/zh-CN/docs/DOM/element.scrollHeight"><code>scrollHeight</code></a> properties might have wrong values when CSS <code>overflow:visible</code> was set on the element. This behavior has been fixed to match the values as if <code>overflow:hidden</code> is set.</p>
+ </section>
+ <section id="sect25">
+ <h3 id="window不再接受自定义的索引属性"><code>window</code>不再接受自定义的索引属性</h3>
+ <ul>
+ <li><a href="https://bugzilla.mozilla.org/show_bug.cgi?id=828787">Bug 828787 – Stop allowing indexed expandos on windows</a></li>
+ </ul>
+ <p>Setting indexed expandos (custom properties which have number as the property name) on the <a href="/zh-CN/docs/DOM/window"><code>window</code></a> object is no longer allowed. Your code like <code>window[2] = "myString"</code> will be ignored from now on.</p>
+ </section>
+ <section id="sect26">
+ <h3 id="window对象上的索引属性变的可枚举"><code>window</code>对象上的索引属性变的可枚举</h3>
+ <ul>
+ <li><a href="https://bugzilla.mozilla.org/show_bug.cgi?id=823228">Bug 823228 - Move indexed properties from nsWindowSH::GetProperty to the outer window proxy</a></li>
+ </ul>
+ <p>Previously, <a href="/zh-CN/docs/HTML/Element/iframe"><code>iframe</code>s</a> in the DOM were not enumerable on the <code>window</code> object. This behavior has been changed to comply with the spec, which means they are now returned with <code>Object.keys(window)</code>. This is important to note for things like global leak detection, since appending <code>iframe</code>s to the document will modify the enumerable keys on the <code>window</code> object.</p>
+ </section>
+ <section id="sect27">
+ <h3 id="XMLHttpRequest.setRequestHeader方法的实现遵循了当前规范"><code>XMLHttpRequest.setRequestHeader</code>方法的实现遵循了当前规范</h3>
+ <ul>
+ <li><a href="https://bugzilla.mozilla.org/show_bug.cgi?id=819051">Bug 819051 – XMLHttpRequest.setRequestHeader() overwrites instead of combines values for the same header.</a></li>
+ </ul>
+ <p>Previously, if the same headers were repeatedly set with <a href="/zh-CN/docs/DOM/XMLHttpRequest#setRequestHeader%28%29"><code>XMLHttpRequest.setRequestHeader</code></a>, the last-specified value was used. This behavior has been changed to comply with the spec, so those values will be properly combined.</p>
+ </section>
+ <section id="sect28">
+ <h3 id="formMethod和formEnctype的默认值成为一个空字符串"><code>formMethod</code>和<code>formEnctype</code>的默认值成为一个空字符串</h3>
+ <ul>
+ <li><a href="https://bugzilla.mozilla.org/show_bug.cgi?id=787095">Bug 787095 – Update formMethod reflection to have the empty string as default value (and 'get' as invalid value)</a></li>
+ <li><a href="https://bugzilla.mozilla.org/show_bug.cgi?id=839171">Bug 839171 – Update formMethod reflection to have the empty string as default value (and 'get' as invalid value)</a></li>
+ </ul>
+ <p>The HTML5 spec of the <a href="/zh-CN/docs/HTML/Element/Input#attr-formmethod"><code>formMethod</code></a> and <a href="/zh-CN/docs/HTML/Element/Input#attr-formenctype"><code>formEnctype</code></a> properties has been updated to have the empty string as default value. Firefox followed the change.</p>
+ </section>
+ <section id="sect29">
+ <h3 id="如果传递多条规则CSSStyleSheet.insertRule方法会报错"><code>如果传递多条规则,CSSStyleSheet.insertRule</code>方法会报错</h3>
+ <ul>
+ <li><a href="https://bugzilla.mozilla.org/show_bug.cgi?id=765599">Bug 765599 – CSSStyleSheet.insertRule should throw when there are more than one rule</a></li>
+ </ul>
+ <p>If multiple rules was passed to the <a href="/zh-CN/docs/DOM/CSSStyleSheet/insertRule"><code>CSSStyleSheet.insertRule</code></a> method, only the first rule was inserted into the stylesheet. Instead, Firefox now throws an exception <code>SYNTAX_ERR</code> like other browsers.</p>
+ </section>
+ <section id="sect30">
+ <h3 id="从NodeIterator和TreeWalker上删除掉expandEntityReferences属性">从<code>NodeIterator</code>和<code>TreeWalker</code>上删除掉<code>expandEntityReferences属性</code></h3>
+ <ul>
+ <li><a href="https://bugzilla.mozilla.org/show_bug.cgi?id=672190">Bug 672190 – consider removing expandEntityReferences from NodeIterator and TreeWalker</a></li>
+ </ul>
+ <p>The <a href="/zh-CN/docs/DOM/NodeIterator.expandEntityReferences"><code>expandEntityReferences</code></a> property, which returned a flag indicating whether or not the children of entity reference nodes were visible to the object, has been removed from the <a href="/zh-CN/docs/DOM/NodeIterator"><code>NodeIterator</code></a> and <a href="/zh-CN/docs/DOM/TreeWalker"><code>TreeWalker</code></a> objects, as it never made much sense.</p>
+ </section>
+ <section id="sect31">
+ <h3 id="CSSKeyframesRule.insertRule方法被改名为appendRule"><code>CSSKeyframesRule.insertRule方法被改名为</code><code>appendRule</code></h3>
+ <ul>
+ <li><a href="https://bugzilla.mozilla.org/show_bug.cgi?id=841896">Bug 841896 – CSSKeyframesRule should have a `appendRule` method, not `insertRule`</a></li>
+ </ul>
+ <p>One of the methods of the <a href="/zh-CN/docs/DOM/CSSKeyframesRule"><code>CSSKeyframesRule</code></a> interface, <code>insertRule</code> has been renamed to <code>appendRule</code> to match a spec change.</p>
+ </section>
+ <section id="sect32">
+ <h3 id="HTMLInputElement.inputmode现在默认被禁用"><code>HTMLInputElement.inputmode</code>现在默认被禁用</h3>
+ <ul>
+ <li><a href="https://bugzilla.mozilla.org/show_bug.cgi?id=857355">Bug 857355 – Hide HTMLInputElement's inputMode API behind a pref and only turn it on for Aurora/Nightly</a></li>
+ </ul>
+ <p><a href="/zh-CN/docs/DOM/HTMLInputElement"><code>HTMLInputElement</code></a>'s <code>inputmode</code> API, which has been <a href="https://bugzilla.mozilla.org/show_bug.cgi?id=746142">implemented</a> since Firefox 17, is now disabled by default because the spec is still unstable. You have to enable the <code>dom.forms.inputmode</code> pref or use the <a href="http://www.mozilla.org/zh-CN/firefox/aurora/">Aurora</a> channel to try out this feature. Note that this API will be renamed <code>inputMode</code> (capitalized <code>M</code>) in <a href="/zh-CN/docs/Site_Compatibility_for_Firefox_22">Firefox 22</a>.</p>
+ </section>
+</section>
+<section id="sect33">
+ <h2 id="JavaScript">JavaScript</h2>
+ <section id="sect34">
+ <h3 id="E4X已经被完全删除">E4X已经被完全删除</h3>
+ <ul>
+ <li><a href="https://bugzilla.mozilla.org/show_bug.cgi?id=788293">Bug 788293 – Remove E4X from Spidermonkey</a></li>
+ </ul>
+ <p>The support of <a href="/zh-CN/docs/E4X">ECMAScript for XML (E4X)</a>, deprecated and disabled since <a href="/zh-CN/docs/Site_Compatibility_for_Firefox_17#E4X_has_been_disabled">Firefox 17</a>, has finally been dropped. You can no longer use the feature regardless of the hidden preference.</p>
+ </section>
+ <section id="sect35">
+ <h3 id="parseInt把以0开头的字符串当成十进制数字解析而不是以前的八进制"><code>parseInt把以0开头的字符串当成十进制数字解析,而不是以前的八进制</code></h3>
+ <ul>
+ <li><a href="https://bugzilla.mozilla.org/show_bug.cgi?id=786135">Bug 786135 – Make parseInt("042") === 42, now that other engines are moving that way</a></li>
+ </ul>
+ <p>The <a href="/zh-CN/docs/JavaScript/Reference/Global_Objects/parseInt"><code>parseInt</code></a> method implementation has been updated to conform to the ECMAScript 5 spec, and it now parses leading-zero strings as decimal, not octal. Therefore, <code>parseInt("042")</code> will return <code>42</code> instead of <code>34</code>. If you'd like to parse strings as octal, specify the radix like <code>parseInt(str, 8)</code>.</p>
+ </section>
+ <section id="sect36">
+ <h3 id="修正String.localeCompare在无参情况下的表现以符合ES5规范">修正<code>String.localeCompare</code>在无参情况下的表现,以符合ES5规范</h3>
+ <ul>
+ <li><a href="https://bugzilla.mozilla.org/show_bug.cgi?id=789393">Bug 789393 – String.prototype.localeCompare() with no argument always returns 0</a></li>
+ </ul>
+ <p>The <a href="/zh-CN/docs/JavaScript/Reference/Global_Objects/String/localeCompare"><code>String.localeCompare</code></a> method implementation has been updated to conform to the latest ECMAScript 5 spec. If no argument is passed, the method takes the <code>"undefined"</code> string as the argument.</p>
+ </section>
+</section>
+<section id="sect37">
+ <h2 id="SVG">SVG</h2>
+ <section id="sect38">
+ <h3 id="删除掉那些未实现的SVG特性">删除掉那些未实现的SVG特性</h3>
+ <ul>
+ <li><a href="https://bugzilla.mozilla.org/show_bug.cgi?id=824218">Bug 824218 – Remove unimplemented SVG features</a></li>
+ </ul>
+ <p>Unimplemented SVG features have been removed instead of just returning the <code>NOT_IMPLEMENTED</code> errors. These features include the <code>viewport</code> and <code>currentView</code> properties of <a href="/zh-CN/docs/DOM/SVGSVGElement"><code>SVGSVGElement</code></a>.</p>
+ </section>
+</section>
+<section id="sect39">
+ <h2 id="AudioVideo">Audio/Video</h2>
+ <section id="sect41">
+ <h3 id="mozAudioContext属性脱前缀"><code>mozAudioContext</code>属性脱前缀</h3>
+ <ul>
+ <li><a href="https://bugzilla.mozilla.org/show_bug.cgi?id=833631">Bug 833631 – Unprefix mozAudioContext</a></li>
+ </ul>
+ <p>The <code>mozAudioContext</code> implementation has been unprefixed. It's still <a href="https://bugzilla.mozilla.org/show_bug.cgi?id=788310">disabled by default</a>, though. To try out this feature, change the value of the <code>media.webaudio.enabled</code> pref to <code>true</code>.</p>
+ </section>
+</section>
+<section id="sect42">
+ <h2 id="安全">安全</h2>
+ <section id="sect43">
+ <h3 id="CSP实现更新到符合最新规范">CSP实现更新到符合最新规范</h3>
+ <ul>
+ <li><a href="https://bugzilla.mozilla.org/show_bug.cgi?id=746978">Bug 746978 – sync CSP directive parsing and directive names with w3c CSP 1.0 spec</a></li>
+ <li><a href="https://bugzilla.mozilla.org/show_bug.cgi?id=783049">Bug 783049 – CSP : use existing/old parser for X-Content-Security-Policy header, new/CSP 1.0 spec compliant parser for Content-Security-Policy header</a></li>
+ </ul>
+ <p>Content Security Policy (CSP) 1.0 spec has been implemented. The existing parser will be used when a policy is served via the <code>X-Content-Security-Policy</code> header, and the new parser that follows the 1.0 spec will be used when a policy is served via the officially spec'd <code>Content-Security-Policy</code> header. Consult the latest spec if you'd like to implement CSP on your site. The <a href="/zh-CN/docs/Security/CSP">documents on MDN</a> will be updated sometime soon.</p>
+ </section>
+</section>