Showfor broken on IE7

VERIFIED FIXED in 1.4.2

Status

support.mozilla.org
Knowledge Base Software
P1
critical
VERIFIED FIXED
9 years ago
9 years ago

People

(Reporter: zzxc, Assigned: jsocol)

Tracking

({regression})

unspecified
1.4.2
All
Windows XP
regression
Bug Flags:
in-litmus +

Firefox Tracking Flags

(Not tracked)

Details

(Whiteboard: sumo_only showfor, URL)

Attachments

(4 attachments, 1 obsolete attachment)

(Reporter)

Description

9 years ago
A user in Live Chat is reporting that showfor content for all operating systems is appearing on IE7, rather than hiding content for other systems.  Searching through chat logs, there seem to be a number of other cases where Windows users are confused about Mac instructions in the middle of articles.

SUMO should be fully functional in all versions of IE >=7, and basic functionality should work in IE6.  Could we test to make sure this wasn't regressed?
(Assignee)

Comment 1

9 years ago
In IE 8, and IE 8's IE 7 mode, it works for me.

Stephen or Vishal, can you verify this in a real IE 7 installation?
This works for me in a "native" IE 7 build (that is, IE 7 in Windows XP in a VM).
Created attachment 406787 [details]
Screenshot of default IE 7 view on the test SHOWFOR article
I can confirm this, actually, now that I know what I'm looking for (thx, zzxc).

I'll upload a screenshot that shows the problem (look for the |Option| key reference, and others (that are Mac-specific).
Created attachment 406793 [details]
Screenshot showing the mixed-platform content (reference to the "Option" key for Windows)
Keywords: regression
(Assignee)

Comment 6

9 years ago
Just to clarify (and remind myself) this does occur in IE 8 when in IE 7 mode, now that I know exactly what to look for.

Does SHOWFOR have special markup for lists?
Assignee: nobody → james
Target Milestone: --- → 1.4.2
Testcase for this specific bug up at https://litmus.mozilla.org/show_test.cgi?id=9587 (we can change the testcase to test IE 6 and IE 8 too).
(Assignee)

Updated

9 years ago
Assignee: james → paulc
Priority: -- → P1
Created attachment 408138 [details] [diff] [review]
v1

Uses jQuery instead of previous implementation.

For what it's worth, the problem was in IE7's handling of getAttribute('className') (previously used) -- http://thicksliced.blogspot.com/2006/12/elementgetattributeclass.html (see IE7). I tried figuring this out with raw javascript but the element.className attribute wasn't properly updated in IE7.

This patch was tested on Fx3.5.3, IE 6,7,8.
Attachment #408138 - Flags: review?(james)
(Assignee)

Comment 9

9 years ago
Comment on attachment 408138 [details] [diff] [review]
v1

It hid all options, instead of none of them. (Will include screenshot.)
Attachment #408138 - Flags: review?(james) → review-
(Assignee)

Comment 10

9 years ago
Created attachment 408496 [details]
screenshot

(Technically, this is IE 8 in IE 7 mode, but it matches what I saw in IE 7. I just couldn't easily get a screenshot from the IE 7 VM [no print screen key]).)
(Assignee)

Updated

9 years ago
Assignee: paulc → james
(Assignee)

Comment 11

9 years ago
Created attachment 409141 [details] [diff] [review]
v2

setAttribute('style','...'); does not work in IE < 8. There were also some issues with using String.match()--I replaced strings with RegExps--and there was a variable being redeclared incessantly. I also reversed the order of the for loop to prevent repeated calls to NodeList.length.

Tested in:
WinXP:
- IE 6
- IE 7
- IE 8
- Firefox 3.5
- Chrome
MacOS
- Firefox 3.5
- Safari
Attachment #408138 - Attachment is obsolete: true
Attachment #409141 - Flags: review?(paulc)
Comment on attachment 409141 [details] [diff] [review]
v2

Looks good on IE6,7,8, Fx3.5.3, and Chrome 3.
Attachment #409141 - Flags: review?(paulc) → review+
I should add all of the above for WinXP. I also tested Linux Fx3.5.3.
Flags: in-litmus?
(Assignee)

Comment 14

9 years ago
r54589 (trunk)
Status: NEW → RESOLVED
Last Resolved: 9 years ago
Resolution: --- → FIXED
Verified, FIXED.
Verified on:
Win XP:
- IE 6
- IE 7
- Fx 3.5
Win Vista:
- IE 8
Linux:
- Fx 3.0
Status: RESOLVED → VERIFIED
(Assignee)

Comment 16

9 years ago
r54600 (prod)
Flags: in-litmus? → in-litmus+

Updated

9 years ago
Whiteboard: sumo_only showfor
You need to log in before you can comment on or make changes to this bug.