Revision history [back]

click to hide/show revision 1
initial version

answered 2012-10-26 02:59:34 +0800

MontyPan gravatar image MontyPan

http://xitop.blogspot.com...

Hi Andy,

Let's devide and conquer your problem.

The situation is: 1. There is a button set "width", "height", "image" attributes like this:

<button w:onClick='${something}' width="140px" height="80px" image="foo.png" label="foo" ></button>
  1. The "foo.png" is an image with size 56px * 56px
  2. "w" is "client" name space, let "${something}" run on client.

Based on this situation l wrote this code:

<zk xmlns:w="client">
<zscript>
String something = "alert(\"click trigger\")";
</zscript>
<button w:onClick='${something}' width="140px" height="80px" image="foo.png" label="foo" ></button>
</zk>

In my environment (ZK 6.5 EE, iPad), it will always show the alert message which indicates that onClick is triggered. Based on this result (suppose it can be reproduced in your environment): 1. ZK component works fine. 2. The problem occurs after ZK trigger "onClick", that means this issue happens in the JS you write / import.

Here's my suggestion: 1. Open the Chrome Developer Tool, check if any js error exists. 2. Modify the code like this String javascriptOnClick = "alert(\"click trigger\");" + DHnUILiterals.onClickJavaScriptCall; ensure the click has been triggered already.

Regards, Monty Pan

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