Closing modal window with media-fed iframe on IE clears the whole page

asked 2011-05-06 05:44:20 +0800

cvarona gravatar image cvarona
554 1 6

updated 2011-05-06 05:45:58 +0800

Hi there,

I've come across a very strange behaviour related to iframes with media content displayed on IE9; just try:

<window id="main" title="My First Window" border="normal" width="640px" height="480px">
    <zscript>org.zkoss.util.media.Media media = null;</zscript>
    <button id="bupload" label="Upload" upload="true" onUpload='media = event.getMedia();' />
    <button id="show" label="Show uploaded file in iframe within a modal window">
        <attribute name="onClick"><![CDATA[
        Window mw = new Window();
        mw.setWidth( "640px" );
        mw.setHeight( "480px" );
        mw.setBorder( "normal" );
        mw.setTitle( "Some uploaded content" );
        mw.setClosable( true );
        Iframe iframe = new Iframe();
        iframe.setWidth( "100%" );
        iframe.setHeight( "100%" );
        iframe.setContent( media );
        iframe.setParent( mw );
        mw.setParent( main );

on the online zksandbox. I usually upload some small pdf file and then click on the 'Show button'. This is my experience:

  -with FF and IE versions prior to 9 everything works as expected
  -with IE9
    -sometimes the iframe will display the uploaded pdf and sometimes not
    -if for whichever reason the iframe remains unloaded it's possible to close the modal (highlighted will do as well as far as this thread is concerned) window and everything works as expected
    -if the iframe correctly shows the uploaded pdf
      -in my equivalent local test I get the famous
06-may-2011 12:09:53 org.zkoss.zk.au.http.AuDynaMediar service:141
GRAVE: Failed to load media, /view/z_i0u/dN2Qp4/4721/1/pannekoek_19190000.pdf
>>org.zkoss.zk.ui.ComponentNotFoundException: Component not found: dN2Qp4
      -when I try to close the modal window the whole page gets cleared

I think this might be related to http://www.zkoss.org/forum/listComment/7612/ and the already solved https://sourceforge.net/tracker/?func=detail&aid=3076384&group_id=152762&atid=785191 bug.

Any suggestion/idea?

With kind regards

César Varona

delete flag offensive retag edit

2 Replies

Sort by » oldest newest

answered 2011-05-13 03:06:03 +0800

cvarona gravatar image cvarona
554 1 6


after upgrading to zk 5.0.7 it continues on behaving the same way.

This time I've started the js debugger; the console displays the following message:

HTML1113: Reinicio del modo de documento de Quirks a Estándares de IE9

Any suggestion?

With kind regards

César Varona

link publish delete flag offensive edit

answered 2014-05-20 09:29:15 +0800

pweller gravatar image pweller
41 1

Hi, i know, it's a long time since the last post. But now i have the same Problem sometimes. ZK is 6.5.4. IE is 11 or 10. Also Grids are not rendered properly. The columns have all the same size. Its for me, that the browser didnt know sometimes, how to handle the content.

With kind regards

Wolfgang Hofmeister

link publish delete flag offensive edit
Your reply
Please start posting your answer anonymously - your answer will be saved within the current session and published after you log in or create a new account. Please try to give a substantial answer, for discussions, please use comments and please do remember to vote (after you log in)!

[hide preview]

Question tools




Asked: 2011-05-06 05:44:20 +0800

Seen: 698 times

Last updated: May 20 '14

Support Options
  • Email Support
  • Training
  • Consulting
  • Outsourcing
Learn More