web.xml breaks EL

2005-07-12 Thread Dewitte Rémi
Hi !
I have a simple test jsp :
%@ taglib 
uri=http://java.sun.com/jsp/jstl/core; 
prefix=c %
c:forEach begin=1 end=3 var=ind
h${ind} ${ind}aBaa/h${ind}
/c:forEach

When I delete my web.xml, everything works well but when I reload the context 
with it, the EL replacement doesn't work.
I can't see why.

I have a very simple 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-nameQuestionnaire/display-name

  servlet
servlet-namestruts-action/servlet-name
servlet-classorg.apache.struts.action.ActionServlet/servlet-class
init-param
  param-nameconfig/param-name
  param-value/WEB-INF/struts-config.xml/param-value
/init-param
load-on-startup2/load-on-startup
  /servlet

  !-- Standard Action Servlet Mapping --
  
  servlet-mapping
servlet-namestruts-action/servlet-name
url-pattern*.do/url-pattern
  /servlet-mapping
  
  !-- The Usual Welcome File List --
  welcome-file-list
welcome-fileindex.jsp/welcome-file
welcome-fileindex.html/welcome-file
  /welcome-file-list
/web-app

And WEB-INF/lib contains :
antlr.jar
commons-beanutils.jar
commons-digester.jar
commons-logging.jar
commons-validator.jar
jakarta-oro.jar
jstl.jar
standard.jar
struts.jar
struts-el.jar

Thanks !

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: web.xml breaks EL

2005-07-12 Thread Dewitte Rémi
Thanks very much !
Rémi

Le Mardi 12 Juillet 2005 12:12, Nikola Milutinovic a écrit :
 Dewitte Rémi wrote:
 Hi !
 I have a simple test jsp :
 %@ taglib
  uri=http://java.sun.com/jsp/jstl/core;
  prefix=c %
 c:forEach begin=1 end=3 var=ind
  h${ind} ${ind}aBaa/h${ind}
 /c:forEach
 
 When I delete my web.xml, everything works well but when I reload the
  context with it, the EL replacement doesn't work.
 I can't see why.
 
 I have a very simple 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;

 This is web.xml for a Servlet 2.2 specification and you need 2.4:

 web-app xmlns=http://java.sun.com/xml/ns/j2ee;
 xmlns:xsi=http://www.w3.org/2001/XMLSchema-instance;
 xsi:schemaLocation=http://java.sun.com/xml/ns/j2ee
 http://java.sun.com/xml/ns/j2ee/web-app_2_4.xsd; version=2.4

 Nix.


 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Tiles

2005-07-11 Thread Dewitte Rémi
Hi !
I make a definition in which i put a list of tiles to include but I can't 
achieve to do this eg :
in my tiles-defs.xml :
definition name=page1-def extends=baseDef
put name=page value=1/
putList name=listQuestions
add value=/Q/firstName.jsp/
add value=/Q/lastName.jsp/
/putList
/definition

And in my template, i don't know how to iterate in listQuestions in order to 
include /Q/firstName.jsp and /Q/lastName.jsp.
A start : 
  tiles:importAttribute/
  c:out value=${listQuestions}/
  c:forEach items=${listQuestions} var=question
What to do to include question !
  /c:forEach

Maybe it's not possible...
Thanks.
Rémi

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Tiles

2005-07-11 Thread Dewitte Rémi
Yes i did, i made a mistake.
Sorry !
Rémi

Le Lundi 11 Juillet 2005 11:24, Christoph Kutzinski a écrit :
 This is a Struts/Tiles related question, you should ask in the Struts
 mailing lists.

 Dewitte Rémi wrote:
  Hi !
  I make a definition in which i put a list of tiles to include but I can't
  achieve to do this eg :
  in my tiles-defs.xml :
  definition name=page1-def extends=baseDef
  put name=page value=1/
  putList name=listQuestions
  add value=/Q/firstName.jsp/
  add value=/Q/lastName.jsp/
  /putList
  /definition
 
  And in my template, i don't know how to iterate in listQuestions in order
  to include /Q/firstName.jsp and /Q/lastName.jsp.
  A start :
tiles:importAttribute/
c:out value=${listQuestions}/
c:forEach items=${listQuestions} var=question
  What to do to include question !
/c:forEach
 
  Maybe it's not possible...
  Thanks.
  Rémi
 
  -
  To unsubscribe, e-mail: [EMAIL PROTECTED]
  For additional commands, e-mail: [EMAIL PROTECTED]

 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: iterate on a value

2005-07-01 Thread Dewitte Rémi
Thanks for your solutions.
Rémi

Le Vendredi 1 Juillet 2005 08:16, Nikola Milutinovic a écrit :
 David Rickard wrote:
  If you don't mind mixing Struts and JSTL, use a c:forEach loop, with
  the end value being the number of children parameters;
 
  At 11:00 AM 6/30/2005, Dewitte Rémi wrote:
  Hello !
  In my form , i ask the number of children. On the next page, i'd like to
  display as many textboxes as children to get their name.
  logic:iterate provides iteration on array or collection, how can i
  iterate
  on the number of children ?

 A word of caution on mixing Struts and JSTL - there are situation when
 it breaks. I've had a webapp, using Struts 1.1 and JSTL 1.0 (Jakarta
 JSTL) and the application did not want to deploy at all. When removed
 JSTL, it ran just fine.

 As for the original question, well, the Action class in between those
 two requests can build an array for iteration. It is ugly, but it works.

 Nix.


 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



iterate on a value

2005-06-30 Thread Dewitte Rémi
Hello !
In my form , i ask the number of children. On the next page, i'd like to 
display as many textboxes as children to get their name.
logic:iterate provides iteration on array or collection, how can i iterate 
on the number of children ?
Thanks !

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



trimSpaces doesn't work

2005-06-29 Thread Dewitte Rémi
It seems my web.xml isn't correct while i still get empty lines. Is it a known 
problem ? 

Thanks in advance.

Here web.xml is :

web-app
  display-nameQuestionnaire/display-name

  servlet
servlet-namestruts-action/servlet-name
servlet-classorg.apache.struts.action.ActionServlet/servlet-class
init-param
  param-nameconfig/param-name
  param-value/WEB-INF/struts-config.xml/param-value
/init-param
load-on-startup2/load-on-startup
  /servlet
  
  servlet
        servlet-namejsp/servlet-name
        servlet-classorg.apache.jasper.servlet.JspServlet/servlet-class
        init-param
            param-namemodificationTestInterval/param-name
            param-value30/param-value
        /init-param
init-param
            param-namegenStrAsCharArray/param-name
            param-valuetrue/param-value
        /init-param
init-param
            param-namedevelopment/param-name
            param-valuefalse/param-value
        /init-param
init-param
            param-nametrimSpaces/param-name
            param-valuetrue/param-value
        /init-param
        load-on-startup3/load-on-startup
    /servlet
  !-- Standard Action Servlet Mapping --
  
  servlet-mapping
servlet-namestruts-action/servlet-name
url-pattern*.do/url-pattern
  /servlet-mapping
  servlet-mapping
servlet-namejsp/servlet-name
url-pattern*.jsp/url-pattern
  /servlet-mapping


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]