views:

143

answers:

1

I'm currently working with jQuery 1.4.2 and jQuery UI 1.8.2.

I'm experiencing some weird behavior after I have closed a modal dialog. When I try to reload the page with Ctrl+F5 nothing happens. Another weird thing is that the context menu of Firefox can only be opened with right clicking twice.

The Firebug console is showing me the following message when I press the Ctrl key: The ‘charCode’ property of a keydown-event should not be used. The value is meaningless.

Demo page: http://testing.allinonesoftware.com/jquery/index.php

Luke

A: 

This is the intended behavior...however there is a browser difference here. Firefox is not focusing inside your dialog on open.

If you click outside the modal and try F5 in any other browser, same effect, no refresh.
Also, if you click inside the modal with Firefox, your F5 will work.

To make this behavior consistent across browsers, focus the element you're making the dialog on open, or if you want, focus one of the buttons...either will have the same effect, as long as the keypress goes inside the dialog.

For the error message:

The ‘charCode’ property of a keydown-event should not be used. The value is meaningless.

This is just how jQuery does some things, you can ignore it...it has no impact on your current issue.

Nick Craver
Thank you for your response. I've found the problem. The jQuery dialog code had been 'fixed' for another problem. I've reverted the fixes and it's working correctly now.
LukeClayroad