-
FEATURED COMPONENTS
First time here? Check out the FAQ!
Hi i need use zk taglib in jsp...
in first line in jsp i write this declaration:
<%@page contentType='text/html' pageEncoding='UTF-8'%>
<%@ taglib uri="http://www.zkoss.org/jsp/zul" prefix="zk" %>
the taglib declaration apears correct but follow error appears:
"The absolute uri: http://www.zkoss.org/jsp/zul cannot be resolved in either web.xml or the jar files deployed with this application"
have some configuration in web.xml?
what a problem???
hi,
try to copy paste this code in your web.xml...
Regards!
<?xml version="1.0" encoding="UTF-8"?>
<web-app xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://java.sun.com/xml/ns/javaee" xmlns:web="http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd" xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd" id="WebApp_ID" version="2.5">
<display-name>Testjsp</display-name>
<listener>
<description>
Used to cleanup when a session is destroyed</description>
<display-name>
ZK Session cleaner</display-name>
<listener-class>org.zkoss.zk.ui.http.HttpSessionListener</listener-class>
</listener>
<listener>
<description>ZK JSP Tags environment initiation </description>
<display-name>ZK JSP Initiator</display-name>
<listener-class>org.zkoss.jsp.spec.JspFactoryContextListener</listener-class>
</listener>
<servlet>
<description>
The servlet loads the DSP pages</description>
<servlet-name>dspLoader</servlet-name>
<servlet-class>
org.zkoss.web.servlet.dsp.InterpreterServlet</servlet-class>
</servlet>
<servlet>
<description>
The ZK loader for ZUML pages</description>
<servlet-name>zkLoader</servlet-name>
<servlet-class>
org.zkoss.zk.ui.http.DHtmlLayoutServlet</servlet-class>
<init-param>
<param-name>update-uri</param-name>
<param-value>/zkau</param-value>
</init-param>
<load-on-startup>1</load-on-startup>
</servlet>
<servlet>
<description>
The asynchronous update engine for ZK</description>
<servlet-name>auEngine</servlet-name>
<servlet-class>
org.zkoss.zk.au.http.DHtmlUpdateServlet</servlet-class>
</servlet>
<servlet-mapping>
<servlet-name>dspLoader</servlet-name>
<url-pattern>*.dsp</url-pattern>
</servlet-mapping>
<servlet-mapping>
<servlet-name>zkLoader</servlet-name>
<url-pattern>*.zul</url-pattern>
</servlet-mapping>
<servlet-mapping>
<servlet-name>zkLoader</servlet-name>
<url-pattern>*.zhtml</url-pattern>
</servlet-mapping>
<servlet-mapping>
<servlet-name>auEngine</servlet-name>
<url-pattern>/zkau/*</url-pattern>
</servlet-mapping>
<welcome-file-list>
<welcome-file>index.html</welcome-file>
<welcome-file>index.htm</welcome-file>
<welcome-file>index.jsp</welcome-file>
<welcome-file>default.html</welcome-file>
<welcome-file>default.htm</welcome-file>
<welcome-file>default.jsp</welcome-file>
<welcome-file>index.zul</welcome-file>
</welcome-file-list>
</web-app>
i try but doesn't work... i too use struts 1.2 in my project...
how i can use it?
thx
hi,
My suggestion is to start with a simple zul page without struts...
else if you like to work with the framework struts, i think that you must define the url of the zkjsp.jar in your web.xml file....the same things that the declaration of the .jar of the framework struts...
Regards
Asked: 2009-07-27 18:45:43 +0800
Seen: 445 times
Last updated: Jul 28 '09