0

ZK執行js的問題

asked 2009-09-28 08:48:40 +0800

adam4891288 gravatar image adam4891288
657 1 5

<zk>
  <script type="text/JavaScript">
    <![CDATA[ 
      function test(tbxsss) {
        var sssval = "Time: "+(new Date()); 
        tbxsss.value = sssval;
      }
    ]]> 
  </script>
  <window id="win" title="My First Window" border="normal" width="200px">
  <textbox id="sss" value="test"/>
  <button id="btn" label="Invoke JS" action="onclick:test(#{sss})"/>
  </window>
  </zk>

這是在網上找到的關於使用js給ZK組件賦值的程式碼。

Clients.evalJavaScript("function test(tbxsss) {alert(1);}test(#{sss});");

delete flag offensive retag edit
Be the first one to reply this discussion!
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

RSS

Stats

Asked: 2009-09-28 08:48:40 +0800

Seen: 354 times

Last updated: Sep 28 '09

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