Re: struts token

2006-05-19 Thread Manfred Wolff
Yes, you can. The token will be stored in the request.



temp temp wrote:
 Can I use  struts token mechanism for an action without a form bean ?
 Thanks  Regards
   
   
   
 -
 Yahoo! Messenger with Voice. PC-to-Phone calls for ridiculously low rates.
   

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



Re: the right way?

2006-05-19 Thread Jorge Martín Cuervo


El 19/05/2006, a las 1:23, Paul Benedict escribió:


This looks right to me. Except you don't put any objects
in the request. Remember, setting redirect=true creates a new
HTTP request and those parameters will not pass to the next page.
-- Paul



i know how the redirect=true attribute works. Thanks for the advise.
And yes, theres no putting objects code in the above message. Only a  
comment in place...


/*
 * load the data to request
 */


thanks again.


--- Jorge Martín Cuervo [EMAIL PROTECTED] wrote:


Hi all,

i have the problem to populate request with data with validation. If
the validation process causes errors, the flow never arrives to
Action processing and no objets in request were send to jsp.

I've solved but i'm not sure if that is the correct way.

Can anyone take a look?

thanks

[...]
action path=/Employer

type=com.defactops.smartcvweb.struts.action.EmployerAction
name=employer
validate=false
input=smartcv.employer
parameter=view,save,default=view

forward name=view path=smartcv.employer/
forward name=success path=/SearchMap.do redirect=true/

/action
[...]


/*
  * $Id: EmployerAction.java,v 1.1 2006/05/18 17:17:54 jorge Exp $
  * $Log: EmployerAction.java,v $
  * Revision 1.1  2006/05/18 17:17:54  jorge
  * prueba employer
  *
  */
package com.defactops.smartcvweb.struts.action;

import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;

import org.apache.struts.action.ActionErrors;
import org.apache.struts.action.ActionForm;
import org.apache.struts.action.ActionForward;
import org.apache.struts.action.ActionMapping;
import org.apache.struts.actions.EventActionDispatcher;

import com.defactops.smartcvweb.struts.actionform.EmployerForm;

/**
  *
  * @author Jorge Martin Cuervo [EMAIL PROTECTED]
  *
  */
public class EmployerAction extends BaseAction {

public ActionForward execute(ActionMapping mapping, ActionForm form,
HttpServletRequest request, HttpServletResponse 
response) throws
Exception {

EventActionDispatcher dispatcher = new 
EventActionDispatcher(this);

return dispatcher.execute(mapping, form, request, response);
}

public ActionForward view(ActionMapping mapping, ActionForm form,
HttpServletRequest request, HttpServletResponse 
response) throws
Exception {


return mapping.findForward(view);
}   


public ActionForward save(ActionMapping mapping, ActionForm form,
HttpServletRequest request, HttpServletResponse 
response) throws
Exception {


/*
 * load the data to request
 */

		ActionErrors errors = ((EmployerForm)form).validate(mapping,  
request);

addErrors(request, errors);

if (errors.isEmpty()) {
return mapping.findForward(success);
} else {
return mapping.getInputForward();
}
}
}



--
Jorge Martín Cuervo

email: [EMAIL PROTECTED]
voz: +34 660 026 384
--



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





__
Do You Yahoo!?
Tired of spam?  Yahoo! Mail has the best spam protection around
http://mail.yahoo.com

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



--
Jorge Martín Cuervo

email: [EMAIL PROTECTED]
voz: +34 660 026 384
--




Re: ERROR: Provider org.apache.xerces.jaxp.DocumentBuilderFactoryImpl not found

2006-05-19 Thread C. Grobmeier
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

Stupid question first:
does one of these archives: xercesImpl.jar or xml-apis.jar contain:
'DocumentBuilderFactoryImpl'.

Chris

Miller, Andy wrote:
 First off, my apologies if I am sending this email to the wrong list.  I
 have searched high and low on the web for answers to this question
 (including posting on the Java Developer forum), but I am not having any
 luck resolving my problem.
 
  
 
 I'm running Java Sun System Web Server 6.1 SP5 on Windows Server 2003.
 I've deployed a 3rd party web application that works properly.  I have
 also written/deployed my own servlet/struts web application that works
 properly (by itself).  The 3rd party application allows for some
 customization (i.e., you can add links in that application to point to
 other locations).  I have added a link that points from the 3rd party
 web application to MY web application.
 
 The problem occurs when I do the following steps (in this exact order):
 1. Deploy MY war file on the web server.
 2. Bounce the web server.
 3. Access the 3rd party application in a web browser.
 4. Click on a link in the 3rd party application that points to MY
 application.
 
 At this point I get an error (see the stack trace at the end of this
 email).  I DO NOT get this error if I access MY application BEFORE
 attempting to access the 3rd party application.
 
 The 3rd party application has included the following jars (among others)
 in /WEB-INF/lib:
 xercesImpl.jar and xml-apis.jar
 
 And also, the 3rd party application requires the addition of the
 following JVM option:
 
 -Djavax.xml.parsers.SAXParserFactory=org.apache.crimson.jaxp.SAXParserFa
 ctoryImpl
 
  
 
 Things I've tried include:
 
 *  Adding xercesImpl.jar, and xml-apis.jar to MY /WEB-INF/lib
 directory.  Did not help.
 
 *  Adding xercesImpl.jar, and xml-apis.jar to the web server
 common directory (\Sun\WebServer6.1\bin\https\jar), and also adding the
 jar files to my classpath.  Did not help.
 
 *  Adding the following code to an initialization servlet in MY
 application:
 System.setProperty(javax.xml.parsers.DocumentBuilderFactory,
 org.apache.xerces.jaxp.DocumentBuilderFactoryImpl);  Did not help.
 
  
 
 My guess is that the 3rd party application is loading/using Xerces.
 Then when my application loads up, my application is attempting to use a
 different XML parser during struts forwarding, and the failure happens
 (I should note that the error occurs when my application attempts to
 forward from the a servlet  to a .jsp).
 
  
 
 I've been searching the web for 2 straight days now and I'm no closer to
 a solution than when I started.  If anybody can help I would REALLY
 appreciate it...thx!
 
 
 stack trace:
 
 failure ( 2580): for host my host trying to GET
 /WebAdvisorButte/searchClasses.do, service-j2ee reports:
 ApplicationDispatcher[/WebAdvisorButte] WEB2649: Servlet.service() for
 servlet jsp threw exception
 javax.servlet.ServletException: Provider
 org.apache.xerces.jaxp.DocumentBuilderFactoryImpl not found
 at com.iplanet.ias.web.jsp.JspServlet.service(JspServlet.java:387)
 at javax.servlet.http.HttpServlet.service(HttpServlet.java:908)
 at
 org.apache.catalina.core.ApplicationDispatcher.invoke(ApplicationDispatc
 her.java:772)
 at
 org.apache.catalina.core.ApplicationDispatcher.doForward(ApplicationDisp
 atcher.java:471)
 at
 org.apache.catalina.core.ApplicationDispatcher.forward(ApplicationDispat
 cher.java:382)
 at
 org.apache.struts.action.RequestProcessor.doForward(RequestProcessor.jav
 a:1062)
 at
 org.apache.struts.action.RequestProcessor.processForwardConfig(RequestPr
 ocessor.java:386)
 at
 org.apache.struts.action.RequestProcessor.process(RequestProcessor.java:
 229)
 at
 org.apache.struts.action.ActionServlet.process(ActionServlet.java:1196)
 at org.apache.struts.action.ActionServlet.doGet(ActionServlet.java:414)
 at javax.servlet.http.HttpServlet.service(HttpServlet.java:787)
 at javax.servlet.http.HttpServlet.service(HttpServlet.java:908)
 at
 org.apache.catalina.core.StandardWrapperValve.invokeServletService(Stand
 ardWrapperValve.java:771)
 at
 org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValv
 e.java:322)
 at
 org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:5
 09)
 at
 org.apache.catalina.core.StandardContextValve.invoke(StandardContextValv
 e.java:212)
 at
 org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:5
 09)
 at
 org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java
 :209)
 at
 org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:5
 09)
 at
 com.iplanet.ias.web.connector.nsapi.NSAPIProcessor.process(NSAPIProcesso
 r.java:161)
 at com.iplanet.ias.web.WebContainer.service(WebContainer.java:580)
 - Root Cause -
 javax.xml.parsers.FactoryConfigurationError: Provider
 org.apache.xerces.jaxp.DocumentBuilderFactoryImpl not found
 at
 

arg variable into a bean:message?

2006-05-19 Thread José María Tristán
Hello,
is posible have and arg of a message that it's a tag of the file
resources.proerties?

Por example:

Resources.properties

label.name=antonio
label.address=c/address

label.sum=live in {0}

and the jsp

bean:message key=label.sum arg(0)=label.address/

Thank you very much.


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



Shale Unit Testing

2006-05-19 Thread Robert Alexandersson
Hello.

I will start developing a application using Shale, for personal use.
This time I want to start the right way, meaning I want to build it
Testdriven, or at least creating testcases for it.

Are there some exampleapplications that use the Shale-Test-Framework. I
saw there are a couple of example apps in the shale-build, so the real
question is are there other apps out there using Shale-Testdriven
development?

Any starting helpers are appreciated.

I will also make it using the Clay variant, meaning no logic at all in
view. Any pointers here are also welcome! I know there are examples in
the examples-app so don't just say look in them.

Regards
Robert A


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



The Last Word re: All hail shale

2006-05-19 Thread Wendy Bossons
May I just say that I saw no offense to Dakota Jack's response to my 
humorous commentary, but that I did find offensive the reaction to it.


Enough said, and I'm done, please don't reply to this thread.

..\Wendy


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

Re: struts token

2006-05-19 Thread temp temp
Can you tell me how can I use struts token mechanisim with out a form bean?
  Thanks  Regards
  

Manfred Wolff [EMAIL PROTECTED] wrote:  Yes, you can. The token will be 
stored in the request.



temp temp wrote:
 Can I use  struts token mechanism for an action without a form bean ?
 Thanks  Regards
   
   
   
 -
 Yahoo! Messenger with Voice. PC-to-Phone calls for ridiculously low rates.
   

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




-
Ring'em or ping'em. Make  PC-to-phone calls as low as 1¢/min with Yahoo! 
Messenger with Voice.

RE: ERROR: Provider org.apache.xerces.jaxp.DocumentBuilderFactoryImplnot found

2006-05-19 Thread Miller, Andy
 does one of these archives: xercesImpl.jar or xml-apis.jar contain:
'DocumentBuilderFactoryImpl'.
Yes, xercesImpl.jar contains that class...

Andy Miller
IS Designer
Butte College
530.895.2946

-Original Message-
From: C. Grobmeier [mailto:[EMAIL PROTECTED] 
Sent: Friday, May 19, 2006 12:39 AM
To: Struts Users Mailing List
Subject: Re: ERROR: Provider
org.apache.xerces.jaxp.DocumentBuilderFactoryImplnot found

-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

Stupid question first:
does one of these archives: xercesImpl.jar or xml-apis.jar contain:
'DocumentBuilderFactoryImpl'.

Chris

Miller, Andy wrote:
 First off, my apologies if I am sending this email to the wrong list.
I
 have searched high and low on the web for answers to this question
 (including posting on the Java Developer forum), but I am not having
any
 luck resolving my problem.
 
  
 
 I'm running Java Sun System Web Server 6.1 SP5 on Windows Server 2003.
 I've deployed a 3rd party web application that works properly.  I have
 also written/deployed my own servlet/struts web application that works
 properly (by itself).  The 3rd party application allows for some
 customization (i.e., you can add links in that application to point to
 other locations).  I have added a link that points from the 3rd party
 web application to MY web application.
 
 The problem occurs when I do the following steps (in this exact
order):
 1. Deploy MY war file on the web server.
 2. Bounce the web server.
 3. Access the 3rd party application in a web browser.
 4. Click on a link in the 3rd party application that points to MY
 application.
 
 At this point I get an error (see the stack trace at the end of this
 email).  I DO NOT get this error if I access MY application BEFORE
 attempting to access the 3rd party application.
 
 The 3rd party application has included the following jars (among
others)
 in /WEB-INF/lib:
 xercesImpl.jar and xml-apis.jar
 
 And also, the 3rd party application requires the addition of the
 following JVM option:
 

-Djavax.xml.parsers.SAXParserFactory=org.apache.crimson.jaxp.SAXParserFa
 ctoryImpl
 
  
 
 Things I've tried include:
 
 *  Adding xercesImpl.jar, and xml-apis.jar to MY /WEB-INF/lib
 directory.  Did not help.
 
 *  Adding xercesImpl.jar, and xml-apis.jar to the web server
 common directory (\Sun\WebServer6.1\bin\https\jar), and also adding
the
 jar files to my classpath.  Did not help.
 
 *  Adding the following code to an initialization servlet in
MY
 application:
 System.setProperty(javax.xml.parsers.DocumentBuilderFactory,
 org.apache.xerces.jaxp.DocumentBuilderFactoryImpl);  Did not help.
 
  
 
 My guess is that the 3rd party application is loading/using Xerces.
 Then when my application loads up, my application is attempting to use
a
 different XML parser during struts forwarding, and the failure happens
 (I should note that the error occurs when my application attempts to
 forward from the a servlet  to a .jsp).
 
  
 
 I've been searching the web for 2 straight days now and I'm no closer
to
 a solution than when I started.  If anybody can help I would REALLY
 appreciate it...thx!
 
 
 stack trace:
 
 failure ( 2580): for host my host trying to GET
 /WebAdvisorButte/searchClasses.do, service-j2ee reports:
 ApplicationDispatcher[/WebAdvisorButte] WEB2649: Servlet.service() for
 servlet jsp threw exception
 javax.servlet.ServletException: Provider
 org.apache.xerces.jaxp.DocumentBuilderFactoryImpl not found
 at com.iplanet.ias.web.jsp.JspServlet.service(JspServlet.java:387)
 at javax.servlet.http.HttpServlet.service(HttpServlet.java:908)
 at

org.apache.catalina.core.ApplicationDispatcher.invoke(ApplicationDispatc
 her.java:772)
 at

org.apache.catalina.core.ApplicationDispatcher.doForward(ApplicationDisp
 atcher.java:471)
 at

org.apache.catalina.core.ApplicationDispatcher.forward(ApplicationDispat
 cher.java:382)
 at

org.apache.struts.action.RequestProcessor.doForward(RequestProcessor.jav
 a:1062)
 at

org.apache.struts.action.RequestProcessor.processForwardConfig(RequestPr
 ocessor.java:386)
 at

org.apache.struts.action.RequestProcessor.process(RequestProcessor.java:
 229)
 at

org.apache.struts.action.ActionServlet.process(ActionServlet.java:1196)
 at
org.apache.struts.action.ActionServlet.doGet(ActionServlet.java:414)
 at javax.servlet.http.HttpServlet.service(HttpServlet.java:787)
 at javax.servlet.http.HttpServlet.service(HttpServlet.java:908)
 at

org.apache.catalina.core.StandardWrapperValve.invokeServletService(Stand
 ardWrapperValve.java:771)
 at

org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValv
 e.java:322)
 at

org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:5
 09)
 at

org.apache.catalina.core.StandardContextValve.invoke(StandardContextValv
 e.java:212)
 at

org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:5
 09)
 at

org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java
 :209)
 at


Re: [OT] HttpRequestWrapper Deprecations?

2006-05-19 Thread Dave Newton
Joe Hertz wrote:
 2) Why didn't I see these deprecations in the 1.4.2 JDK? Seems like I should 
 have gotten them all along. But that would imply Tomcat 5.x isn't compliant 
 with the 2.1 spec, and I can't believe that. I assume it's error on my part.
   

Were you compiling with deprecation warnings on?

 I'm now beginning to think the HttpServletRequest/Response *interface* wasn't 
 deprecated until the 1.5 JDK and every servlet container's implementations is 
 now generating these warnings. I'm just wondering why the Tomcat group never 
 fixed theirs. Again, I'm assuming I'm wrong.
   

The HttpServletRequest/Response interfaces aren't in JDK 1.5, they're in
J2EE.

Dave



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



Re: Another problem of Tiles:the display-tag can NOT display using paging.

2006-05-19 Thread M.Liang Liu

I've fixed through documents of display-tag.

The requestURL of the display:table should be the page which uses
Layout.jsp,not the content page using display-tag.

Sorry to trouble you all.


On 5/20/06, M.Liang Liu [EMAIL PROTECTED] wrote:


I tried to use display-tag http://displaytag.sf.net/ to show tables in
my little project and it works well.
However,a problem occured when I tried to make use of Auto-paging in my
struts Tiles.


I put one page displaying table using display-tag into my one of my
Layout.jsp and the first page can display properly.The problem comes when
I clicked the next-page-button.
The exception is:

 javax.servlet.ServletException: Error - tag.getAsString : component context 
is not defined. Check tag syntax

org.apache.jasper.runtime.PageContextImpl.doHandlePageException(PageContextImpl.java:848)
org.apache.jasper.runtime.PageContextImpl.handlePageException

 (PageContextImpl.java:781)

org.apache.jsp.tiles.layouts.Layout_jsp._jspService(org.apache.jsp.tiles.layouts.Layout_jsp:107)
org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:97)
javax.servlet.http.HttpServlet.service

 (HttpServlet.java:802)

org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:322)
org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:291)
org.apache.jasper.servlet.JspServlet.service

 (JspServlet.java:241)
javax.servlet.http.HttpServlet.service(HttpServlet.java:802)

com.eam.filters.CharsetEncodingFilter.doFilter(CharsetEncodingFilter.java:27)


And I am sure the  CharsetEncodingFilter is right.

Anyone familiar with display-tag?What should I do if I hold on struts 1.2and 
Tiles?

Thanks a lot!





--
 http://blog.csdn.net/patriotlml
   Drink   Drank Drunk
http://my.donews.com/patriotlml/


Re: struts token

2006-05-19 Thread Manfred Wolff
Hi mr. temp.temp

1. The Action calls saveToken(request);
2. A unique token will be generated and saved in the session and in the
jsp as a hidden field.
3. The next action calls |*isTokenValid
http://struts.apache.org/struts-doc-1.2.x/api/org/apache/struts/action/Action.html#isTokenValid%28javax.servlet.http.HttpServletRequest,%20boolean%29(request,
true);
4. If the token in the request match the token in the session everything
is alright. Otherwise the user has gone back and the token in the
request is not valid.
5. True means, the token will be reseted. Otherwise you have to reset it
on your own with the method resetToken(request).

Manfred*|


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



RE: Another problem of Tiles:the display-tag can NOT display using paging.

2006-05-19 Thread David G. Friedman
Your errors suggests a tile error, not a displaytag
error.  How are you tiles defined and what is the 
1st table page url and the next page url shown
in your browser window?

Regards,
David

-Original Message-
From: M.Liang Liu [mailto:[EMAIL PROTECTED]
Sent: Friday, May 19, 2006 12:25 PM
To: Struts Users Mailing List
Subject: Another problem of Tiles:the display-tag can NOT display using
paging.


I tried to use display-tag http://displaytag.sf.net/ to show tables in my
little project and it works well.
However,a problem occured when I tried to make use of Auto-paging in my
struts Tiles.


I put one page displaying table using display-tag into my one of my
Layout.jsp and the first page can display properly.The problem comes when I
clicked the next-page-button.
The exception is:

 javax.servlet.ServletException: Error - tag.getAsString : component context 
 is not defined. Check tag syntax
   
 org.apache.jasper.runtime.PageContextImpl.doHandlePageException(PageContextImpl.java:848)
   org.apache.jasper.runtime.PageContextImpl.handlePageException
 (PageContextImpl.java:781)
   
 org.apache.jsp.tiles.layouts.Layout_jsp._jspService(org.apache.jsp.tiles.layouts.Layout_jsp:107)
   org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:97)
   javax.servlet.http.HttpServlet.service
 (HttpServlet.java:802)
   
 org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:322)
   org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:291)
   org.apache.jasper.servlet.JspServlet.service
 (JspServlet.java:241)
   javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
   
 com.eam.filters.CharsetEncodingFilter.doFilter(CharsetEncodingFilter.java:27)


And I am sure the  CharsetEncodingFilter is right.

Anyone familiar with display-tag?What should I do if I hold on struts
1.2and Tiles?

Thanks a lot!


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



Re: Another problem of Tiles:the display-tag can NOT display using paging.

2006-05-19 Thread M.Liang Liu

Thank you David G. Friedman .

It is really an error about next page url.I fixed it by changing the
requestURL of the display-tag table.

Thanks for your info and it works.

Anyone pointing a better way?
On 5/20/06, David G. Friedman [EMAIL PROTECTED] wrote:


Your errors suggests a tile error, not a displaytag
error.  How are you tiles defined and what is the
1st table page url and the next page url shown
in your browser window?

Regards,
David

-Original Message-
From: M.Liang Liu [mailto:[EMAIL PROTECTED]
Sent: Friday, May 19, 2006 12:25 PM
To: Struts Users Mailing List
Subject: Another problem of Tiles:the display-tag can NOT display using
paging.


I tried to use display-tag http://displaytag.sf.net/ to show tables in
my
little project and it works well.
However,a problem occured when I tried to make use of Auto-paging in my
struts Tiles.


I put one page displaying table using display-tag into my one of my
Layout.jsp and the first page can display properly.The problem comes when
I
clicked the next-page-button.
The exception is:

 javax.servlet.ServletException: Error - tag.getAsString : component
context is not defined. Check tag syntax
   org.apache.jasper.runtime.PageContextImpl.doHandlePageException(
PageContextImpl.java:848)
   org.apache.jasper.runtime.PageContextImpl.handlePageException
 (PageContextImpl.java:781)
   org.apache.jsp.tiles.layouts.Layout_jsp._jspService(
org.apache.jsp.tiles.layouts.Layout_jsp:107)
   org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:97)
   javax.servlet.http.HttpServlet.service
 (HttpServlet.java:802)
   org.apache.jasper.servlet.JspServletWrapper.service(
JspServletWrapper.java:322)
   org.apache.jasper.servlet.JspServlet.serviceJspFile(
JspServlet.java:291)
   org.apache.jasper.servlet.JspServlet.service
 (JspServlet.java:241)
   javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
   com.eam.filters.CharsetEncodingFilter.doFilter(
CharsetEncodingFilter.java:27)


And I am sure the  CharsetEncodingFilter is right.

Anyone familiar with display-tag?What should I do if I hold on struts
1.2and Tiles?

Thanks a lot!


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





--
 http://blog.csdn.net/patriotlml
   Drink   Drank Drunk
http://my.donews.com/patriotlml/


Re: struts token

2006-05-19 Thread temp temp
What hidden field should I use in jsp to pass the generated token to next 
action class?  
Thanks  Regards
  
Manfred Wolff [EMAIL PROTECTED] wrote:  Hi mr. temp.temp

1. The Action calls saveToken(request);
2. A unique token will be generated and saved in the session and in the
jsp as a hidden field.
3. The next action calls |*isTokenValid
(request,
true);
4. If the token in the request match the token in the session everything
is alright. Otherwise the user has gone back and the token in the
request is not valid.
5. True means, the token will be reseted. Otherwise you have to reset it
on your own with the method resetToken(request).

Manfred*|


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




-
New Yahoo! Messenger with Voice. Call regular phones from your PC and save big.

change URL in action?

2006-05-19 Thread fea jabi

c:url value=/DispatchAction.do var=addUrl
   c:param name=method value=add/
/c:url
html:link href=${addUrl} transaction=true
   fmt:message key=lbl.addlink bundle=${appbundle}/
/html:link

have the above code in jsp. when the user cliks on the link, and when the 
action method is executing want to change the URL to


...PrepareAction.do instead of having the url as

.PrepareAction.do?method=addTOKEN=...


Is it possible to do this? if so how do the same?

I tried putting

private ActionFoward add() {


   request.getRequestURL();
   return mapping.findForward(successAdd);

}

but still URL was the same as before.

Thanks.

_
FREE pop-up blocking with the new MSN Toolbar – get it now! 
http://toolbar.msn.click-url.com/go/onm00200415ave/direct/01/



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



Re: struts token

2006-05-19 Thread Michael Jouravlev

Search for renderToken() in FormTag.java:

http://svn.apache.org/viewvc/struts/action/trunk/taglib/src/main/java/org/apache/struts/taglib/html/FormTag.java?view=markup

Michael.

On 5/19/06, temp temp [EMAIL PROTECTED] wrote:

What hidden field should I use in jsp to pass the generated token to next 
action class?
Thanks  Regards

Manfred Wolff [EMAIL PROTECTED] wrote:  Hi mr. temp.temp

1. The Action calls saveToken(request);
2. A unique token will be generated and saved in the session and in the
jsp as a hidden field.
3. The next action calls |*isTokenValid
(request,
true);
4. If the token in the request match the token in the session everything
is alright. Otherwise the user has gone back and the token in the
request is not valid.
5. True means, the token will be reseted. Otherwise you have to reset it
on your own with the method resetToken(request).

Manfred*|


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




-
New Yahoo! Messenger with Voice. Call regular phones from your PC and save big.



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



non-visual automatic jsp design issue + tiles-def

2006-05-19 Thread Chris Pat
 Hello
In a tiles-def.xml is/how it possible to have a


put namelayoutName value=/listingAction.do?param=123/

Without going to the complexity of a making it a tile then a controller for the 
tile? It appears that value can only be a jsp. 

Alternatively is it possible to create a non-visual jsp that will 
automatically either post a value in the session and forward to an action or do 
a virtual Submit to a defined action with no visual display or user input?


-
Feel free to call! Free PC-to-PC calls. Low rates on PC-to-Phone.  Get Yahoo! 
Messenger with Voice

is there any way to customize the client side validation popup window

2006-05-19 Thread Lixin Chu

Hi All,
would like to know if there is any way to customize the client side
validation popup window ? i am using struts client side validator.
thanks
lixin


RE: is there any way to customize the client side validation popup window

2006-05-19 Thread Chaudhary, Harsh
If you mean the Browser pop up window, then no.

You could think about server side validation and generating custom
pop-ups using Javascript.

Harsh.

-Original Message-
From: Lixin Chu [mailto:[EMAIL PROTECTED] 
Sent: Friday, May 19, 2006 4:59 PM
To: Struts Users Mailing List
Subject: is there any way to customize the client side validation popup
window


Hi All,
would like to know if there is any way to customize the client side
validation popup window ? i am using struts client side validator.
thanks
lixin

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



Null Exception in ActionForm

2006-05-19 Thread red phoenix

I have two jsp file,such a.jsp and b.jsp,one Action file and one Form file,I
want to from a.jsp to call Action file,and I set value of Form in Action
file,and return to b.jsp,and show value in b.jsp,so I can modify this value
in b.jsp
my struts-config.xml is follows:
form-beans
  form-bean
name=TestForm
type=Test.TestForm/
/form-beans
action-mappings
action path=/test
type=Test.TestAction
  name=TestForm
  scope=request
  input=/b.jsp
  forward name=cc path=/b.jsp /
/action
/action-mappings

/*b.jsp*/
...
html:form method=post action=nextTest.do
html:text property=name/
html:text property=card/
/html:form
/*TestForm.java*/
Package Test
...
public class TestForm extends ActionForm{
private String name;
private String card;
public String getName(){
 return name;
}
public String getCard(){
 return card;
}
public void setName(String name){
 this.name=name;
}
public void setCard(String card){
 this.card=card;
}
}

/*TestAction.java*/
Package Test;
...
public class TestAction extends Action{
TestForm f=(TestForm)form;
//here query some data from database
//and put the query result in TestForm
//so it will show them in b.jsp and I can change the value in b.jsp
f.setName(John);
f.setCard(1);
return mapping.findForward(cc);
}

First I show a.jsp page,and there is a href in this page,when click this
href and it will point to /test,but it raise error,it say Null exception at
f.setName(John) in TestAction.java,I guess TestForm may be  null.How to
do to realize put some value in Form through Action and put return to
b.jspshow and may modify these value in
b.jsp?

Thanks in advance


what is the best practice?

2006-05-19 Thread Joel Alejandro Espinosa Carra

Hi all.

I think this is kind of a basic question. I have an application that 
haves 3 tables: users, messages and user_inbox for the relationship of 
first 2 ones. I have a class named MessagesManager in order to manage 
the messages to-and-from the database throught the business methods, one 
of them is the public List getMessages(String user_id) method that 
returns a MessageBean's list and I need to display the messages of each 
user in a html table, the MessageBean only contains the user_id but I 
want to display their names, do I need to modify my business method in 
order to get the usernames? or do I need to add another method to get 
the usernames, something like public String getName(String user_id)?, 
the first aproach makes one query to the database and the second aproach 
makes two. What is the best practice here?
As you can see english is not my navite language, I hope you guys can 
understand my issue.


Thanks in advance.
Have a nice weekend.

--
Ing. Joel Alejandro Espinosa Carra
CINVESTAV CTS - Centro de Tecnología de Semiconductores
Tel. +52 (33) 3770-3700 ext. 1049
http://www.cts-design.com 



--
Este mensaje ha sido analizado por MailScanner
en busca de virus y otros contenidos peligrosos,
y se considera que está limpio.
MailScanner agradece a transtec Computers por su apoyo.


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



[shale] pom.xml of tiles

2006-05-19 Thread Yoshitaka Tanaka
Hi,

I tried buiding shale-starter by maven2. insted of ant.

Then, I found a diference between  groupId's structure in pom.xml and
structure of repository for tiles.

In
http://people.apache.org/maven-snapshot-repository/org/apache/struts/shale/shale-tiles/1.0.3-SNAPSHOT/shale-tiles-1.0.3-SNAPSHOT.pom
:
groupIdorg.apache.tiles/groupId
  artifactIdtiles-core/artifactId
  version0.2-SNAPSHOT/version

In http://people.apache.org/maven-snapshot-repository/ :
org/apache/*struts*/tiles/tiles-core/0.2-SNAPSHOT/

Is it a mistake in pom.xml ?

Thanks,
Yoshitaka


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



HELP:I've got a new problem when I tried to use struts-menu in my Tiles using display-tag.

2006-05-19 Thread M.Liang Liu

Hi everybody!

  I've got a new problem when I tried to use struts-menu in my Tiles using
display-tag.

I put the struts-menu in my Tiles alone and find it works well.
However,the problem occurred when I put one page using display-tag in the
same Tiles page including struts-menu:The struts-menu can NOT display
properly.The image can display  but  the menu  has  a rim.I do NOT want the
rim because every menu has one-there are so many that the menu was
dissipated .
I can NOT stand it.


I can not enclosed the strange screen picture of the  page  as
attachments;so I put it  in my   flickr
herehttp://static.flickr.com/53/149590641_0cbeeb81b6_o.jpg
.

Anyone who's familiar with display-tag can help me?

Please.


Re: HELP:I've got a new problem when I tried to use struts-menu in my Tiles using display-tag.

2006-05-19 Thread M.Liang Liu

In the Tomcat 5.5.x  logs  file ,there's no more info.

As following:


log4j:WARN No appenders could be found for logger (
org.apache.catalina.startup.TldConfig).
log4j:WARN Please initialize the log4j system properly.
log4j:WARN No appenders could be found for logger (
org.apache.catalina.session.ManagerBase).
log4j:WARN Please initialize the log4j system properly.
log4j:WARN No appenders could be found for logger (
org.apache.catalina.session.ManagerBase).
log4j:WARN Please initialize the log4j system properly.
log4j:WARN No appenders could be found for logger (
org.apache.catalina.startup.TldConfig).
log4j:WARN Please initialize the log4j system properly.
log4j:WARN No appenders could be found for logger (
org.apache.catalina.session.ManagerBase).
log4j:WARN Please initialize the log4j system properly.
log4j:WARN No appenders could be found for logger (
org.apache.catalina.session.ManagerBase).
log4j:WARN Please initialize the log4j system properly.



On 5/20/06, M.Liang Liu [EMAIL PROTECTED] wrote:


Hi everybody!

   I've got a new problem when I tried to use struts-menu in my Tiles
using display-tag.

I put the struts-menu in my Tiles alone and find it works well.
However,the problem occurred when I put one page using display-tag in the
same Tiles page including struts-menu:The struts-menu can NOT display
properly.The image can display  but  the menu  has  a rim.I do NOT want
the rim because every menu has one-there are so many that the menu was
dissipated .
I can NOT stand it.


I can not enclosed the strange screen picture of the  page  as
attachments;so I put it  in my   flickr 
herehttp://static.flickr.com/53/149590641_0cbeeb81b6_o.jpg
.

Anyone who's familiar with display-tag can help me?

Please.





--
 http://blog.csdn.net/patriotlml
   Drink   Drank Drunk
http://my.donews.com/patriotlml/


Re: Shale Unit Testing

2006-05-19 Thread Craig McClanahan

On 5/19/06, Robert Alexandersson [EMAIL PROTECTED]
wrote:


Hello.

I will start developing a application using Shale, for personal use.
This time I want to start the right way, meaning I want to build it
Testdriven, or at least creating testcases for it.

Are there some exampleapplications that use the Shale-Test-Framework. I
saw there are a couple of example apps in the shale-build, so the real
question is are there other apps out there using Shale-Testdriven
development?

Any starting helpers are appreciated.



Don't just look at the runtime examples ... look at the source code.  The
use cases example app, for example :-), includes unit tests that leverage
the test framework to exercise the backing beans in the webapp itself.

Craig


I will also make it using the Clay variant, meaning no logic at all in

view. Any pointers here are also welcome! I know there are examples in
the examples-app so don't just say look in them.

Regards
Robert A


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




drop down links.

2006-05-19 Thread Abhimanyu Koul
Hi!
I am using drop down menus using javascript im my application. i want to know 
how can we use html:link in those cases for the individual entry of the drop 
down menu.
since it doesn't use any a href
Abhimanyu Koul
FinEng Solutions (P)  Ltd.
Dani Compound,
158, Vidyanagari Marg,
Kalina, Santacruz (East),
Mumbai - 400 098
Mobile : +91 9860582533