0

I just built a dialog box to create new documents including a few editble fields and file upload following Chris Toohey's great blog entry. This solution uses an iFrame inside an ExtLib dialog to work around a limitation of that control. But testing it in Firefox (V 20) all of the usually editable fields appear to be blocked: clicking in them the cursor just blinks shortly and then obiously is sent some place else; looks as if something would perform a js .blur() method, but there isn't any to be found. All butttons on the page work, though. So I can upload files, but I cannot enter values into fields in my dialog (using FF, see below). What's even more strange here: as soon as I right-click in some field then select Firebug's "Examine element with Firebug" all fields in the form are open to be edited, and they stay that way until I close the dialog.

I just tried the same thing using MSIE (camptibility as well as IE8 modes): here I first was prompted to allow the site "about:blank" to be opened in this context. As soon as I did allow it, everything was fine: I can edit fields, upload files etc. in my dialog. Not so in FF.

Somehow it appears as if some security setting would prevent the form to be edited, maybe preventing some XSS or something. But I can't find any setting in FF that would allow my site being loaded into my dialog's iFrame.

Update: I just added this client side script to one of those fields' onblur event:

alert("go away!")

And indeed, if I bring up the dialog and click into that field the first time the alert is fired up. And: from then on all fields are available.

Update #2: just placed another editBox ("outerField") inside the dialog but outside of the iFrame. Also I created a new very simple Xpage to be loaded into the iFrame. The new simple Xpage only contains a single editBox ("innerField"), nothing else. Result is like that: after loading the dialog the cursor automatically is put into the "outerField". Clicking into "innerField" the cursor is sent immediately back to "outerField"...

Update #3: tried a few things on top:

  • Google Chrome behaves just like FF
  • created an Xpage holding the very same custom control that hosts the iframe etc. Result: if I run the stuff in its own page everything's fine. So it must be the extlib dialog that's causing trouble here
  • finally tried the sandbox attributes with the iframe tag, without any visible difference
Lothar Mueller
  • 2,528
  • 1
  • 16
  • 29

1 Answers1

0

Magic! I really don't what that is or was. All of a sudden it's working now, and in all brwosers. I simply left the code alone for a few days and all of a sudden it's working as expected. Weird!

Lothar Mueller
  • 2,528
  • 1
  • 16
  • 29