Bug Tracker

Opened 7 years ago

Closed 7 years ago

Last modified 6 years ago

#12135 closed bug (worksforme)

Opera find(:checked) fails on frame navigation

Reported by: MrMamen Owned by: MrMamen
Priority: undecided Milestone: None
Component: unfiled Version: 1.7.2
Keywords: Cc:
Blocked by: Blocking:

Description

http://jsfiddle.net/mrmamen/3kKgE/

This is a rather obscure error, and not so easy to reproduce with jsFiddle, due to the fact that the links are rewritten. But the current version seems to be working more or less.

1. Try checking one or more checkboxes.
2. Then click the link
3. If the link just refreshes the frame, start from 1. This usually happens the first time only
4. Right click the frame, and navigate back.
5. Observe that the checkbox(es) you checked in step 1 is still checked.
6. Click the button. Result is always 0.

"is" selector seems to be working {is(:checked) returns true} Tested in Opera 12. Seems to be working in other browsers.

Change History (5)

comment:1 Changed 7 years ago by dmethvin

Owner: set to MrMamen
Status: newpending

Huh? The link isn't valid. What exactly is this trying to do?

I wasn't able to reproduce the problem using this fiddle and Opera 12.00 Windows. If there is a problem, I'd guess that there is some strangeness because of the cached state of the page, possibly combined with the fact that the link is 404. Perhaps you can refine the test, show the native check values, and make it more reliable? Even a dedicated page somewhere if that's needed.

comment:2 Changed 7 years ago by MrMamen

Status: pendingnew

JSfiddle rewrites my links, even if I include protocol. Where it links is not important. Anyway I have an updated testcase with more debugging here: http://folk.ntnu.no/bronner/temp/checkbox-back-bug.html

I first assumed that it had to be inside a frame, but as you can see, it doesn't matter. Dragonfly seems to confirm that the property is checked. The "is" filter seems to catch this, but find(":checked") returns 0 always.

Test this by checking any number of checkboxes, click on the link to google, and click back. Now press the button.

I hope this helps. It seems like a Opera bug to me, but you can probably investigate it further.

comment:3 Changed 7 years ago by sindresorhus

Can't reproduce the issue with the testcase above on Opera 12.01 OS X.

comment:4 Changed 7 years ago by dmethvin

Resolution: worksforme
Status: newclosed

It seems like a Opera bug to me, but you can probably investigate it further.

Sorry but our group of volunteers isn't equipped to act as a central frontend for every browser's bug tracker.

I still can't make this fail in Opera 12.00.1467 Windows 7. Try creating a JS-and-DOM-only test case and report it directly to Opera.

comment:5 Changed 6 years ago by anonymous

be warned: jquery has no work around for opera weird back-button behaviour:

upon back button, opera tries to preserve the checkboxes states, but alas on domready event the checkboxes are not checked yet!

the will became checked after the domready event, but not fully; find('input:checked') wont find them! use find('input').filter(':checked') instead and dont forget to call the find code in a setTimeout callback from the domready handler as a workaround

uf - this have just eaten 2h of my time

Note: See TracTickets for help on using tickets.