0

ZK The JSP Pages

asked 2008-05-16 05:42:42 +0800

admin gravatar image admin
18691 1 10 130
ZK Team


Orignial message at:
https://sourceforge.net/forum/message.php?msg_id=4966335

By: firedup0205

Hic.. HenriChen and Dennis Chen tell some discussions to read Small talks ..
to embeded ZUL tags inside JSP Pages by one linked they post.. but I can't open that page! ???

..... In ...ZK Small Talks - Work with Legacy Web Applications, Part II
- JSP...

..........................Step 1.................................
inside WEB-INF/web.xml <========== note

I changed this whole code:
<!-- Uncomment if you want to use the ZK filter to post process the HTML output
generated by other technology, such as JSP and velocity.
<filter>
<filter-name>zkFilter</filter-name>
<filter-class>org.zkoss.zk.ui.http.DHtmlLayoutFilter</filter-class>
<init-param>
<param-name>extension</param-name>
<param-value>html</param-value>
</init-param>
<init-param>
<param-name>compress</param-name>
<param-value>true</param-value>
</init-param>
</filter>
<filter-mapping>
<filter-name>zkFilter</filter-name>
<url-pattern>/test/filter.dsp</url-pattern>
</filter-mapping>
<filter-mapping>
<filter-name>zkFilter</filter-name>
<url-pattern>/test/filter2.dsp</url-pattern>
</filter-mapping>
-->

By this code: <================= note
<filter>
<filter-name>zkFilter</filter-name>
<filter-class>org.zkoss.zk.ui.http.DHtmlLayoutFilter</filter-class>
<init-param>
<param-name>extension</param-name>
<param-value>html</param-value> <!-- Use XHTML components as default. -->
</init-param>
</filter>
<filter-mapping>
<filter-name>zkFilter</filter-name>
<url-pattern>*.jsp</url-pattern>
<dispatcher>REQUEST</dispatcher>
<dispatcher>INCLUDE</dispatcher>
<dispatcher>FORWARD</dispatcher>
<dispatcher>ERROR</dispatcher>
</filter-mapping>

.............................Step 2......................
//In Test.jsp:


<form action="Processing.jsp" xmlns:x="http://www.zkoss.org/2005/zul">
<table>

<tr>
<td>Title</td>
<td><x:textbox name="txtUserName" value=""/></td>
</tr>
<tr>
<td>
<input type="submit" value="Update"/>
</td>
<td>
<input type="reset"/>
</td>
</tr>
</table>
</form>

................Result...............
It work very well ... that I mixed ZK Tags inside JSP Page (^^) Hiiii .......... But...Huuu..Huu..Hu...
All the JSP Page which are not mixed ZK Tags by namespace (I use <jsp:include....>) is error (if not change Web.xml they work well).... <======Help me!

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: 2008-05-16 05:42:42 +0800

Seen: 183 times

Last updated: May 16 '08

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