User "Krinkle" changed the status of MediaWiki.r80116.

Old Status: fixme
New Status: resolved

User "Krinkle" also posted a comment on MediaWiki.r80116.

Full URL: http://www.mediawiki.org/wiki/Special:Code/MediaWiki/80116#c22447
Commit summary:

Fixed IE bug, you must use html:msg for the msg elements that jquery.localize 
uses to translate things otherwise IE chokes when you insert them cause it 
doesn't know about the msg element.

Comment:

Marking this 'resolved' (due to lack for a better choise). Explanation / 
Time-line:

* Originally jquery.localize wanted to use a custom tag {{tag|msg|o}}.
* Problem: IE doesn't like unknown elements, needs <code>createElement()</code> 
hack to even make it behave properly. But that still leaves issues when trying 
to select it from JavaScript in some cases (ie. when not being in the 
"document"). This was attempted to be fixed by this revision ({{r|80116}}), but 
as said. Still leaves unsolved issues.
* Solution: Use "<code>html:msg</code>" instead of "<code>msg</code>", which IE 
seems to not have a struggle with selecting from.
* Realisation: We now have two tags documented, we don't want to have people 
using them mixed and uncover bugs in one way and not in other ways. We wanna 
stick to 1 standard.
* Idea: Drop support for "{{tag|msg|o}}"-support and just stick to 
{{tag|html:msg|o}}, which as we learned works great in IE and other browsers 
are OK with it as well.
* Action: {{r|92329}}: Remove "{{tag|msg|o}}"-support, only keep 
"{{tag|html:msg|o}}" (we weren't using "{{tag|msg|o}}" anywhere in existing 
code, including all of <code>/trunk/extensions</code>)
* Realisation: OMG, something broke! IE6/7 cannot select {{tag|html:msg|o}}
* Discovery: Apparently, in the past few months, it wasn't the addition of 
<code>html:msg</code> that magically fixed it for IE. It was the presence of 
both that made IE happy. IE6/7 returns {{tag|html:msg|o}} elements by querying 
elements by tag name "<code>msg</code>". Whereas all other browsers (including 
IE8+) only select them with "<code>html:msg</code>"
* Ultimate solution: Only support {{tag|html:msg|o}} usage in to-be-localized 
html fragments, but keep "<code>msg</code>" in the selector because that's how 
IE6/7 can select those elements. This was done in {{r|92758}}

Amen.

_______________________________________________
MediaWiki-CodeReview mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-codereview

Reply via email to