0

zk upload file IE8 Enterprise Mode

asked 2016-09-20 08:39:28 +0800

hancock46 gravatar image hancock46
13 3

Hi,

I have this button in my zul page with ZK7 version:

<button label="${labels.btn.excel.in}" src="/images/excel.png" upload="true" onUpload="@command('importExcel',upload=event)" />

It works correctly, but I need to execute my web site on a client IE11 but with Enterprise Mode. So I need compatibility with IE8.

But my web page doesn't work with IE8. The problem is the syntax upload="true". If I delete this snippet, the page load correctly but the upload command doesn't work.

Can you help me to solve my problem? I need to execute this page on Enterprise Mode with IE8 compatibility. How can I upload a file?

delete flag offensive retag edit

Comments

can you test with : <fileupload onUpload="@command('...')">

chillworld ( 2016-09-20 13:13:08 +0800 )edit

I tried with <fileupload onUpload="@command('importExcel',upload=event)" /> but I get the same problem. Can you give me other advice?

hancock46 ( 2016-09-20 14:03:40 +0800 )edit

removing upload="true" will of course disable the upload functionality. You say "my web page doesn't work with IE8", which is not very precise. What are the effects? JS errors, browser crash, upload causing server errors ... Please have a look into the browser console and paste the info here. Robert

cor3000 ( 2016-09-21 00:53:00 +0800 )edit

In my page I have a template with 3 parts: an header, a menu and a body. When I click on the page with the upload button, the browser console is empty but the body and the header of the page are white.

hancock46 ( 2016-09-21 07:09:27 +0800 )edit

In Console browser there is also this message but without error: "The attacched page targets document mode 8. Some console APIs and features may not be available."

hancock46 ( 2016-09-21 07:11:30 +0800 )edit

1 Answer

Sort by ยป oldest newest most voted
0

answered 2016-09-21 08:56:25 +0800

cor3000 gravatar image cor3000
4089 1 7
ZK Team

updated 2016-09-21 11:10:49 +0800

the fix applied in ZK-8 involves a z-index of the clickable INPUT element

  <style>
    .ie8 SPAN.z-upload INPUT {
      z-index: 1;
    }
  </style>

runnable fix for emulated IE8: http://zkfiddle.org/sample/3uqgg/2-upload-IE-enterprise-mode

Let's hope this also works in your case.

UPDATE: updated style for 7.0.3 ONLY (<=7.0.2 >=7.0.4 work as stated previously)

  <style>
    .ie8 SPAN.z-upload INPUT {
      z-index: 1;
    }
    .ie8 SPAN.z-upload {
      display: inline-block;
    }
  </style>

http://zkfiddle.org/sample/3uqgg/3-upload-IE-enterprise-mode

Robert

link publish delete flag offensive edit

Comments

Also in this way I get the same error. I use the 7.0.3 CE zk version.

hancock46 ( 2016-09-21 10:25:29 +0800 )edit

updated my response, unexpectedly only 7.0.3 needs an additional workaround style

cor3000 ( 2016-09-21 11:11:45 +0800 )edit

Hi robert, thanks for your time but also in this way I get the same problem. Can you help me?

hancock46 ( 2016-09-23 09:16:38 +0800 )edit

now things go beyond the possibilities in this forum. I can't look into your system, and I can hardly take the extra time to randomly try to reproduce your issue. You'll have to check the generated HTML and the styles. there should be a transparent form - overlaying the visual button.

cor3000 ( 2016-09-23 09:43:20 +0800 )edit

If that form does not fully cover the button, it will not receive mouse clicks and the file upload will not trigger (still assuming that's the only problem here).

cor3000 ( 2016-09-23 09:44:06 +0800 )edit
Your answer
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

Follow
1 follower

RSS

Stats

Asked: 2016-09-20 08:39:28 +0800

Seen: 19 times

Last updated: Sep 21 '16

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