tomcat-taglibs-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Delagrange, Morgan" <mdela...@us.britannica.com>
Subject RE: Application-Tag
Date Tue, 23 Jan 2001 16:13:47 GMT
Hi Achim,

The problem is that your goofing up the usage a little.  The variables you
declare inside your web.xml are called "init parameters", not attributes.
(Application attributes are something entirely different.)  Use the init
parameter tags (initparameter, existsinitparameter, equalsinitparameter,
usw. :) to access them.

- Morgan


> -----Original Message-----
> From: "Weßling, Achim" [mailto:Achim.Wessling@gt-net.de]
> Sent: Tuesday, January 23, 2001 9:22 AM
> To: taglibs-user@jakarta.apache.org
> Subject: Application-Tag
> 
> 
> Hi,
> 
> I try to use the attribute-Tag of the Application-TagLib. So 
> I added the
> following in my web.xml:
> 
> <? xml version="1.0" encoding="ISO-8859-1"?>
> <!DOCTYPE web-app PUBLIC "-//Sun Microsystems, Inc.//DTD Web 
> Application
> 2.2//EN" "http://java.sun.com/j2ee/dtds/web-app_2_2.dtd">
> <web-app>
>     <display-name>TagDemo</display-name>
>     <context-param>
>         <param-name>picpath</param-name>
>         <param-value>test</param-value>
>     </context-param>
> 
>     <description>Tag Extension Demo</description>
> 
>     <taglib>.............
> 
> I thought this would declaire a variable with the name 
> 'picpath' and the
> value 'test', but if I try to use it in my jsp-File like this:
> 
> <%@ taglib uri="/infokomGT" prefix="infokomGT"%>
> <HTML>
> 	<HEAD>
> 		<TITLE>User LOGIN to SD-IMS X-Projects</TITLE>
> 		<link REL="stylesheet" HREF="/WebSD/html/sd-ims.css">
> 	</HEAD>
> 	<BODY background="/websd/pics/hin1.jpg">
> 		<H1 align="center">User LOGIN f&uuml;r SD-IMS
> X-Projects</H1>
> 		<BR/><BR/>
> 		Aktuelles Datum: <B><infokomGT:timedate/></B>
> 		</B>
> 		<HR/>
>                 <infokomGT:attribute name="picpath"/>
>                 <infokomGT:equalsattribute name="picpath" 
> match="test">
> 		<BR/>Hier kommt die Wurst<BR/>
>                 </infokomGT:equalsattributeb>
> 		<infokomGT:debug>
> 		Aktuelle Session ID:<%=session.getId()%>
> 		Request:<%= request.getParameter("test")
> %></infokomGT:debug>
> 	</BODY>
> </HTML>
> 
> All Application-Tags will be null. Where is my mistake?
> 
> Thanks a lot!
> 
> Achim Weßling
> 
> **************************************************************
> ************
> INFOKOM Gütersloh
> Fachbereich Technische Anwendungen / Zentrale Anwendungen
> Tel.: 05241/85-2926
> Achim.Wessling@gt-net.de
> 

Mime
View raw message