0

Working with zhtml

asked 2010-05-24 13:01:09 +0800

shumy gravatar image shumy
244 1

Most of the time I what to start an application from a web template (html/css). For that I am working with zhtml, since zul is very attached to ZK styles. But I'm not able to use input components to submit information. My form is a simple login like:

<zk xmlns="http://www.zkoss.org/2005/zk/native"
xmlns:h="http://www.w3.org/1999/xhtml"
xmlns:zul="http://www.zkoss.org/2005/zul"
xmlns:z="http://www.zkoss.org/2005/zk"
xmlns:a="http://www.zkoss.org/2005/zk/annotation">

<style src="style/style.css"/>

<div class="left_box_border">
<div class="left_box">
<span style="color:#7B0E10; font-weight:bold; font-size:14px; padding:10px;">
MEMBERS LOG IN
</span>
<img src="images/user-icon.png" width="37" height="27" alt="user" title="user" />
<h:div id="login" apply="com.antstorytales.site.LoginView">
<label>Username:</label>
<h:input id="user" type="text" class="input" value="@{this.user}"/>

<div class="clear"/>
<label>Password:</label>
<h:input type="password" class="input" value="@{this.password}"/>
<h:input id="submit" type="submit" value="Login" class="submit" />
<div class="clear"/>
<a href="register.zhtml">register</a>
</h:div>
</div>
</div>
</zk>

The LoginView class is not able to catch the values from input components. If I use zul:textbox works fine.
I use the GenericForwardComposer and a "this" variable.
Also even if I use a "Input user" in the composer and try to get the value from "user.getValue()" doesn´t work.

delete flag offensive retag edit

1 Reply

Sort by » oldest newest

answered 2010-05-27 21:17:10 +0800

jumperchen gravatar image jumperchen
3909 2 8
http://jumperchen.blogspo... ZK Team

@ sign is used for Data binding, you shouldn't use this.user in the case.

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

Follow

RSS

Stats

Asked: 2010-05-24 13:01:09 +0800

Seen: 288 times

Last updated: May 27 '10

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