[PATCH] JS Form Popups

Ralf Hoelzer ralf at well.com
Tue Jun 3 20:01:07 BST 2003


This patch that tries to fix Bug #58650:

http://bugs.kde.org/show_bug.cgi?id=58650

 If a JavaScript form.submit() is called and the form has a non-existent 
target specified, a new browser window pops up. This trick to get around 
popup blockers is used
on http://sharereactor.com. 

The patch tries to check if a frame with the target name exists. If not, it 
either blocks it (deny/smart policy) or asks. I've put it into ecma/kjs_html 
to make sure it's only checked if the form is submitted via JS.

I tested this with a few testcases and it works for me. I wasn't sure if a 
frame is allowed to be replaced in a different frameset. That check might 
need to be added.

regards,

Ralf



-------------- next part --------------
A non-text attachment was scrubbed...
Name: form_popup.patch
Type: text/x-diff
Size: 2583 bytes
Desc: not available
URL: <https://mail.kde.org/mailman/private/kfm-devel/attachments/20030603/cc067c3c/attachment.patch>


More information about the kfm-devel mailing list