Re: [Struts Tiles] How to put a list of items to a nested tile?

2007-10-18 Thread Antonio Petrelli
2007/10/17, Christ Jochen [EMAIL PROTECTED]:
 In my layout_with_servicecolumn.jsp I want to insert my tile footer, but
 how to forward my attribute footeritems to this tile?

You cannot do it! You have to create a definition, using footer.jsp
as the template, put the attribute (with putList) in this new
definition and, finally, put this definition as an attribute in
base.definition.

BTW, for Tiles 2.1 there is an open issue to realize this feature:
https://issues.apache.org/struts/browse/TILES-208

Antonio

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



Re: Disable validation when delete button is pressed

2007-10-18 Thread Igor Vlasov

The most elegant method is to give a SPECIAL name to delete  button.
It must looks like:

s:submit name=method:delete value=Delete / 
and
s:submit value=Execute /

I found it in 
http://www.nabble.com/struts2-validation-for-only-one-method-in-action-tf3267302.html
this  post by  Ian Roughley




an Roughley wrote:
 
 you can always use s:submit name=method:delete value=Delete / and
 s:submit value=Execute / - then you don't need the logic to
 determine which button was clicked in the execute() method, and you can
 use the validation config below. 
 


Original Post 


Igor Vlasov wrote:
 
 Hello.
 
 I have 
 s:form action=customer method='post' theme=xhtml  
  s:textfield name=customer.cus_email  size=20 label=E-mail / 
  s:submit value=OK. name=VIEWtheme=simple   /s:submit 
   s:submit value=Delete name=DEL theme=simple/s:submit
 /s:form
 and 
 
 CustomerCRUD-validation:
 validators
   field name=customer.cus_email
 field-validator type=email
   messageError E-mail/message
 /field-validator
   /field
 /validators
 
 
 
 How to DISABLE server side validation when i click on DELETE button and
 have empty email field value ?
 

-- 
View this message in context: 
http://www.nabble.com/Disable-validation-when-%22delete%22-button-is-pressed-tf4640820.html#a13269390
Sent from the Struts - User mailing list archive at Nabble.com.


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



Re: struts2 validation for only one method in action

2007-10-18 Thread Igor Vlasov

Thank you for your answer. It was very helpful.



Ian Roughley wrote:
 
 you can always use s:submit name=method:delete value=Delete / and 
 s:submit value=Execute / - then you don't need the logic to 
 determine which button was clicked in the execute() method, and you can 
 use the validation config below.
 
 /ian
 
 Igor Vlasov wrote:
 This is not a solution.

 I have 2 submit button in one form: one for save and another for delete.
 All
 of them submit the form data to execute() method. There I can determine
 which button was pressed and do  an appropriate bussines action.

 The problem is that i must to validate the data when OK button is
 pressed
 and  NOT validate when DEL button is pressed.


 ros wrote:
   
 For struts it's 
 interceptor-ref name=validation
 cancel,execute,delete,edit,list,print
 /interceptor-ref

 Hope this helps.

 ros


 Igor Vlasov wrote:
 
 And how to disable the SERVER side validation when delete button
 clicked
 ?



 ros wrote:
   
 Java Script validation fro button disabled by 

 s:submit cssClass=button method=delete key=button.delete

 onclick=document.getElementById('ticketForm').onsubmit = null; /


 ros wrote:
 
 If I have in one form DELETE and SAVE buttons, how to turn off client
 side validation for DELETE button?

   
 
   
 

   
 
 

-- 
View this message in context: 
http://www.nabble.com/struts2-validation-for-only-one-method-in-action-tf3267302.html#a13269628
Sent from the Struts - User mailing list archive at Nabble.com.


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



how to use form input in java class

2007-10-18 Thread kushi

Hi

I just devlop a form that upload a file (this form contains a text box  a
command button(OK button)).
my requirement is that when i click on ok button then i call an action named 
action1 .
On this action1 which class is excuted is specified in struts.xml.
In struts.xml i define action class action1class.java .in
action1class.java class  i required file name that i input in textbox.
so how i can use that name in my java class .please give me ur suggestion as
soon as possible.


Thanks in advance.
kushi
-- 
View this message in context: 
http://www.nabble.com/how-to-use-form-input-in-java-class-tf4645786.html#a13270913
Sent from the Struts - User mailing list archive at Nabble.com.


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



Re: how to use form input in java class

2007-10-18 Thread horri khalid
Hi,

First you must create a formAction class that contain elements form like
this:
suppose you a form with a text box and button, so the formActin class is
// import
public class YourFrom extends ActionForm
{
  private String textBoxName;

  // getter and setter textBoxName
}
second you configure struts.xml:
  add a form bean in the tag form-beans
  form-bean  name=aForm path=thePathPackage.YourFrom.javaform-bean
  and
 add this in your action mapping name=aForm

finally you can retreive the textBox value in your action class like this:

   yourForm frm = (form) new yourFrm();
   String txtBxValue =  frm.getTextBoxName();

2007/10/18, kushi [EMAIL PROTECTED]:


 Hi

 I just devlop a form that upload a file (this form contains a text box  a
 command button(OK button)).
 my requirement is that when i click on ok button then i call an action
 named
 action1 .
 On this action1 which class is excuted is specified in struts.xml.
 In struts.xml i define action class action1class.java .in
 action1class.java class  i required file name that i input in textbox.
 so how i can use that name in my java class .please give me ur suggestion
 as
 soon as possible.


 Thanks in advance.
 kushi
 --
 View this message in context:
 http://www.nabble.com/how-to-use-form-input-in-java-class-tf4645786.html#a13270913
 Sent from the Struts - User mailing list archive at Nabble.com.


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




-- 
HORRI Khalid
J2EE Developer
-
PHONE: +(212)22897659
GSM: +(212)77763981


Callback after AJAX call

2007-10-18 Thread Eduardo Yáñez Parareda
Hello, I'm new to Struts 2.
In a project we're using version 2.0.9, and have some questions about AJAX
calls.
How could I call a javascript function after making an AJAX call?

I know that in future 2.1 version there is a afterNotifyTopics parameter
that I could use
to do that, but how could I do it on 2.0.9?

We tried notifyTopics, but this one executes the javascript code before and
after calling.

-- 
Eduardo Yáñez Parareda


Re: Callback after AJAX call

2007-10-18 Thread Alvaro Sanchez-Mariscal
You can include your javasript call in a piece of code in the jsp
which is the result of the action.

Make sure to include executeScripts=true in your link/button.

Alvaro.

On 10/18/07, Eduardo Yáñez Parareda [EMAIL PROTECTED] wrote:
 Hello, I'm new to Struts 2.
 In a project we're using version 2.0.9, and have some questions about AJAX
 calls.
 How could I call a javascript function after making an AJAX call?

 I know that in future 2.1 version there is a afterNotifyTopics parameter
 that I could use
 to do that, but how could I do it on 2.0.9?

 We tried notifyTopics, but this one executes the javascript code before and
 after calling.

 --
 Eduardo Yáñez Parareda



-- 
Alvaro Sanchez-Mariscal Arnaiz
Java EE Architect  Instructor
[EMAIL PROTECTED]

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



Access a SiteMesh Object in a Struts tag

2007-10-18 Thread Grish

Hi,

I was wondering if this is possible, I want to access a SiteMesh object in a
struts tag like the set tag:

I want to access the Page object from SiteMesh and get a property from that
object and assign it a value

decorator:usePage id=myPage /

s:set name=currentPage value= /

where value would be myPage.getProperty(meta.curentPage).

I have a feeling i'm just using incorrect syntax. Can anyone point me to the
right direction?

Thanks!
-- 
View this message in context: 
http://www.nabble.com/Access-a-SiteMesh-Object-in-a-Struts-tag-tf4646229.html#a13272172
Sent from the Struts - User mailing list archive at Nabble.com.


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



[beginner] need to use logic:equal with request attribute

2007-10-18 Thread Marchioni Francesco
Hi all,
I have an action class which sets some attributes 

request.setAttribute(pValueIn, vFlagms);

then it forwards to a jsp page.

Now I'd like to use logic:equal (or another struts tag) which controls the
value of this field

logic:equal name=pValueIn value=VC4S
OK
/logic:equal

 but unfortunately I can see OK get always printed. Whatever value is the
parameter. (Even with another parameter name)
Also tried with 

logic:equal name=pValueIn value=VC4S scope=request

but nothing..
any help ??



 
Le informazioni trasmesse possono contenere documenti confidenziali e/o 
materiale riservato; sono 
quindi da intendersi esclusivamente ad uso della persona e/o società a cui sono 
indirizzate.
Qualsiasi modifica, inoltro, diffusione o altro utilizzo, relativo alle 
informazioni trasmesse, da parte 
di persone e/o società diversi dai destinatari indicati, è proibito ai sensi 
della legge 196/2003. 
Qualora questa mail fosse stata ricevuta per errore, si prega di contattare il 
mittente e cancellarne
il contenuto. 
-- 
Privileged/Confidential Information may be contained in this message. If you 
are not the addressee 
indicated in this message (or responsible for delivery of the message to such 
person), you may not 
copy or deliver this message to anyone. In such case, you should destroy this 
message and kindly 
notify the sender by reply email. Please advise immediately if you or your 
employer does not consent 
to Internet email for messages of this kind. Opinions, conclusions and other 
information in this 
message that do not relate to the official business of my firm shall be 
understood as neither given 
nor endorsed by it. 

 


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



Re: [beginner] need to use logic:equal with request attribute

2007-10-18 Thread Antonio Petrelli
2007/10/18, Marchioni Francesco [EMAIL PROTECTED]:

 Hi all,
 I have an action class which sets some attributes

 request.setAttribute(pValueIn, vFlagms);

 then it forwards to a jsp page.

 Now I'd like to use logic:equal (or another struts tag) which controls the
 value of this field

 logic:equal name=pValueIn value=VC4S
 OK
 /logic:equal

 but unfortunately I can see OK get always printed. Whatever value is the
 parameter. (Even with another parameter name)



It does not make sense, the way  you specify logic:equal is correct,
but
I once had a similar problem, and in that case I forgot to specify the
taglib in the JSP page.
Are you sure you specified the logic tag library correctly?

Antonio


Problem in s:text tag

2007-10-18 Thread shan99


I have a tag like this
s:textarea name=txtMsg cssStyle=width: 200px
key=PROGRAM_SETTINGS
/

and also i have a radio buttin calld chkText
I wnt to chang thr key of the  s:text if user select 'yes' of that radio
buttopn
so i have to use a java script so how can i change the key os S:text from
the java script
-- 
View this message in context: 
http://www.nabble.com/struts2-validation-for-only-one-method-in-action-tf3267302.html#a13272200
Sent from the Struts - User mailing list archive at Nabble.com.


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



R: [beginner] need to use logic:equal with request attribute

2007-10-18 Thread Marchioni Francesco
thanks it was that. I needed to put
%@ taglib uri=/WEB-INF/taglib.tld prefix=ndctags%
at the beginning.

But very very odd because Eclipse can see those tags even without the tag
lib
specification...( I mean there's auto-completation of that tag).

anyway thanks !

It does not make sense, the way  you specify logic:equal is correct,
but
I once had a similar problem, and in that case I forgot to specify the
taglib in the JSP page.
Are you sure you specified the logic tag library correctly?

Antonio

-Messaggio originale-
Da: Antonio Petrelli [mailto:[EMAIL PROTECTED]
Inviato: giovedì 18 ottobre 2007 13.56
A: Struts Users Mailing List
Oggetto: Re: [beginner] need to use logic:equal with request attribute


2007/10/18, Marchioni Francesco [EMAIL PROTECTED]:

 Hi all,
 I have an action class which sets some attributes

 request.setAttribute(pValueIn, vFlagms);

 then it forwards to a jsp page.

 Now I'd like to use logic:equal (or another struts tag) which controls the
 value of this field

 logic:equal name=pValueIn value=VC4S
 OK
 /logic:equal

 but unfortunately I can see OK get always printed. Whatever value is the
 parameter. (Even with another parameter name)






 
Le informazioni trasmesse possono contenere documenti confidenziali e/o 
materiale riservato; sono 
quindi da intendersi esclusivamente ad uso della persona e/o società a cui sono 
indirizzate.
Qualsiasi modifica, inoltro, diffusione o altro utilizzo, relativo alle 
informazioni trasmesse, da parte 
di persone e/o società diversi dai destinatari indicati, è proibito ai sensi 
della legge 196/2003. 
Qualora questa mail fosse stata ricevuta per errore, si prega di contattare il 
mittente e cancellarne
il contenuto. 
-- 
Privileged/Confidential Information may be contained in this message. If you 
are not the addressee 
indicated in this message (or responsible for delivery of the message to such 
person), you may not 
copy or deliver this message to anyone. In such case, you should destroy this 
message and kindly 
notify the sender by reply email. Please advise immediately if you or your 
employer does not consent 
to Internet email for messages of this kind. Opinions, conclusions and other 
information in this 
message that do not relate to the official business of my firm shall be 
understood as neither given 
nor endorsed by it. 

 


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



about Struts 2.0.9 portlet example ...

2007-10-18 Thread Giovanni Azua

hi all,

I managed to see the examples in the portlet webapp demo (there is no 
index page) but I didn't see any portlet anywhere ... so I am curious as 
if to there is at all an AJAX portlet control delivered with Struts 2?


Lack of portlets in S2 and AJAxification of displaytag would be the two 
main reasons for me to use ajaxtags in addition to S2.

Any alternatives to ajaxtags?

regards,
Giovanni


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



Re: about Struts 2.0.9 portlet example ...

2007-10-18 Thread Nils-Helge Garli Hegvik
Hi!

If you're thinking of the struts2-portlet application, you need to
install it into a portlet container to test it. However, ajax is not
yet built into the portlet framework.

Nils-H

On 10/18/07, Giovanni Azua [EMAIL PROTECTED] wrote:
 hi all,

 I managed to see the examples in the portlet webapp demo (there is no
 index page) but I didn't see any portlet anywhere ... so I am curious as
 if to there is at all an AJAX portlet control delivered with Struts 2?

 Lack of portlets in S2 and AJAxification of displaytag would be the two
 main reasons for me to use ajaxtags in addition to S2.
 Any alternatives to ajaxtags?

 regards,
 Giovanni


 -
 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]



urlrewrite

2007-10-18 Thread ros

Hi!

What regular expression can be used to rewrite this URLs:

from  /faq/LANG1/index.html?locale=LANG2   to  
/faq/LANG2/index.html?locale=LANG2

from  /faq/LANG1/foo/index.html?locale=LANG2   to  
/faq/LANG2/foo/index.html?locale=LANG2


Thanks!
-- 
View this message in context: 
http://www.nabble.com/urlrewrite-tf4646563.html#a13273278
Sent from the Struts - User mailing list archive at Nabble.com.


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



struts There is no Action mapped for namespace / and action name

2007-10-18 Thread Ádamo Azambuja
 i Have this problem and i lost 2 days trying do fix, what can i do in this
case?

I use java 1.4.2 / Struts 2 J4 / Hibernate and Spring.

i have the HelloWorld.java in the src and src/action to test.


*struts.xml *
include file=struts-default.xml/

constant name=struts.objectFactory value=
org.apache.struts2.spring.StrutsSpringObjectFactory /

constant name=struts.devMode value=true /
package name=action extends=struts-default
action name=HelloWorld class=HelloWorld
result name=none/HelloWorld.jsp/result
/action
/package

*applicationContext.xml *
bean class=
org.springframework.orm.hibernate3.support.OpenSessionInViewFilter /
bean id=helloWorld
class=HelloWorldAction singleton=false
/bean

*web.xml *
filter
filter-nameSpring OpenEntityManagerInViewFilter/filter-name
filter-class
org.springframework.orm.hibernate3.support.OpenSessionInViewFilter
/filter-class
/filter
filter-mapping
filter-nameSpring OpenEntityManagerInViewFilter/filter-name
url-pattern/*/url-pattern
/filter-mapping
filter
filter-name struts/filter-name
filter-classorg.apache.struts2.dispatcher.FilterDispatcher/filter-c lass

/filter
filter-mapping
filter-namestruts/filter-name
url-pattern/*/url-pattern
/filter-mapping

-- 
Ádamo B. Azambuja
JEE Developer
icq: 112102893
msn: [EMAIL PROTECTED]
E-Mail 1: [EMAIL PROTECTED]
E-Mail 2: [EMAIL PROTECTED]


Re: How to improve dojo performance in Struts 2.0.9

2007-10-18 Thread Pedro Herrera

It´s not working to me. why don´t you leave yours jars available ?

Herrera




Jeromy Evans - Blue Sky Minds wrote:
 
 As suggested, I've added these instructions to the community wiki.
 
 http://cwiki.apache.org/confluence/display/S2WIKI/Creating+a+custom+Dojo+profile+for+Struts+2.0.9
 
 Wes Wannemacher wrote:
 This was my original suggestion to post it into the community wiki
 because any changes that would be made to the main wiki may not
 propagate until the next release of struts (2.1.x?) which this may no
 longer be an issue. I figured it could be posted there and if the
 powers that be know a special way to tie it to the 2.0 docs, we could
 push it in. If not, at least it would stay in the community wiki.

 -W

 On 10/9/07, Don Brown [EMAIL PROTECTED] wrote:
   
 To add to that, there are really two wiki's - official docs (WW) and
 the informal docs (S2WIKI),
 

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

-- 
View this message in context: 
http://www.nabble.com/How-to-improve-dojo-performance-in-Struts-2.0.9-tf4579700.html#a13273769
Sent from the Struts - User mailing list archive at Nabble.com.


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



Re: How to improve dojo performance in Struts 2.0.9

2007-10-18 Thread Jeromy Evans

Pedro Herrera wrote:

It´s not working to me. why don´t you leave yours jars available ?

Herrera

  

Hi Pedro,
I can't really create a jar for you because its not appropriate to 
extract part of struts out and then redistribute it.  I could create a 
script I suppose, but the problem is mostly solved in struts 2.1 already.


If you let me know where the instructions fall-short maybe I can help a 
little better?


regards,
Jeromy Evans

Jeromy Evans - Blue Sky Minds wrote:
  

As suggested, I've added these instructions to the community wiki.

http://cwiki.apache.org/confluence/display/S2WIKI/Creating+a+custom+Dojo+profile+for+Struts+2.0.9





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



Adding S2 into existing servlet project

2007-10-18 Thread Justin Frost

I am new to Struts and have an existing web project that uses servlets right
now.
I am trying to add S2 to my existing project.

When I add my s2 config info in web.xml and redeploy my application I get a
blank page instead of my original default.jsp.  

http://localhost:16624/support/  should bring up my default jsp page.

The page source of the blank page that is displayed is as follows:

!DOCTYPE HTML PUBLIC -//W3C//DTD HTML 4.0 Transitional//EN
HTMLHEAD
META http-equiv=Content-Type content=text/html;
charset=windows-1252/HEAD
BODY/BODY/HTML

I assure you that the actual jsp has info in it.  In fact if I remove the
setup info for S2 in web.xml the page displays fine.



My web.xml is:
?xml version=1.0 encoding=UTF-8?
web-app id=WebApp version=2.4 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;
display-name
SupportWeb/display-name

!-- New Struts 2 setup --
filter
filter-namestruts2/filter-name
   
filter-classorg.apache.struts2.dispatcher.FilterDispatcher/filter-class
/filter

filter-mapping
filter-namestruts2/filter-name
url-pattern/*/url-pattern
/filter-mapping
!-- --
!-- Existing Servlets --   
servlet
display-name
SupportServlet/display-name
servlet-nameSupportServlet/servlet-name
servlet-class
com.hdx.support.tools.servlet.SupportServlet/servlet-class
/servlet
servlet
display-name
RouterInterfaceTestServlet/display-name
servlet-nameRouterInterfaceTestServlet/servlet-name
servlet-class

com.hdx.support.tools.servlet.RouterInterfaceTestServlet/servlet-class
/servlet
servlet
display-name
QuerySvcTestFileServlet/display-name
servlet-nameQuerySvcTestFileServlet/servlet-name
servlet-class

com.hdx.support.tools.servlet.QuerySvcTestFileServlet/servlet-class
/servlet
servlet
display-name
QuerySvcFormServlet/display-name
servlet-nameQuerySvcFormServlet/servlet-name
servlet-class

com.hdx.support.tools.servlet.QuerySvcFormServlet/servlet-class
/servlet
servlet
display-name
PostTestServlet/display-name
servlet-namePostTestServlet/servlet-name
servlet-class
com.hdx.test.servlet.PostTestServlet/servlet-class
/servlet
servlet
display-name
PrintContentsTestServlet/display-name
servlet-namePrintContentsTestServlet/servlet-name
servlet-class
com.hdx.test.servlet.PrintContentsTestServlet/servlet-class
/servlet
servlet
description
/description
display-name
LaunchServlet/display-name
servlet-nameLaunchServlet/servlet-name
servlet-class
com.hdx.support.tools.servlet.LaunchServlet/servlet-class
/servlet
servlet-mapping
servlet-nameSupportServlet/servlet-name
url-patternSupportServlet/url-pattern
/servlet-mapping
servlet-mapping
servlet-nameSupportServlet/servlet-name
url-patternsupport/url-pattern
/servlet-mapping
servlet-mapping
servlet-nameRouterInterfaceTestServlet/servlet-name
url-patternRouterInterfaceTest/url-pattern
/servlet-mapping
servlet-mapping
servlet-nameQuerySvcTestFileServlet/servlet-name
url-patternQuerySvcFile/url-pattern
/servlet-mapping
servlet-mapping
servlet-nameQuerySvcFormServlet/servlet-name
url-patternQuerySvcFormServlet/url-pattern
/servlet-mapping
servlet-mapping
servlet-nameQuerySvcFormServlet/servlet-name
url-patternQuerySvcForm/url-pattern
/servlet-mapping
servlet-mapping
servlet-nameRouterInterfaceTestServlet/servlet-name
url-patternrouter1/url-pattern
/servlet-mapping
servlet-mapping
servlet-namePostTestServlet/servlet-name
url-patternposttest/url-pattern
/servlet-mapping
servlet-mapping
servlet-namePrintContentsTestServlet/servlet-name
url-patternprinttest/url-pattern
/servlet-mapping
servlet-mapping
servlet-nameLaunchServlet/servlet-name
url-pattern/LaunchServlet/url-pattern
/servlet-mapping
!-- --

Struts TLD Parse Error

2007-10-18 Thread Peters, John
Good morning,

Using Struts 1.1 running on WebSphere 6.1.
Any ideas on the error below?
I'm getting this same error for struts-html.tld, struts-nested.tld and
struts-bean.tld.
Thanks in advance for any help.

[10/18/07 10:11:14:917 EDT] 0010 jsp   E
com.ibm.ws.jsp.taglib.TldParser logParseErrorMessage Failed to parse Tag
Library [/WEB-INF/struts-tiles.tld]: JSPG0235E: The JSP container failed
to load the TagExtraInfo class
[org.apache.struts.taglib.tiles.UseAttributeTei] 
[10/18/07 10:11:14:933 EDT] 0010 jsp   W
com.ibm.ws.jsp.taglib.TagLibraryCache loadWebXmlMap jsp warning failed
to load tld at [/WEB-INF/struts-tiles.tld]
[10/18/07 10:11:14:933 EDT] 0010 jsp   W
com.ibm.ws.jsp.taglib.TagLibraryCache loadWebXmlMap jsp warning failed
to load tld at [/WEB-INF/struts-tiles.tld]


Blue Cross Blue Shield of Florida, Inc., and its subsidiary and affiliate 
companies are not responsible for errors or omissions in this e-mail message. 
Any personal comments made in this e-mail do not reflect the views of Blue 
Cross Blue Shield of Florida, Inc.  The information contained in this document 
may be confidential and intended solely for the use of the individual or entity 
to whom it is addressed.  This document may contain material that is privileged 
or protected from disclosure under applicable law.  If you are not the intended 
recipient or the individual responsible for delivering to the intended 
recipient, please (1) be advised that any use, dissemination, forwarding, or 
copying of this document IS STRICTLY PROHIBITED; and (2) notify sender 
immediately by telephone and destroy the document. THANK YOU.


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



Re: struts There is no Action mapped for namespace / and action name

2007-10-18 Thread Zarar Siddiqi
Problems that I see:

1. Spring bean is defined as helloWorld but referred to as
HelloWorld in Struts config (case is incorrect).

2. You're saying that your action class is under src/action so I would
think the fully qualified name of the class might be
action.HelloWorldAction but that's now how you're referring to it in
the Spring config.  Also, is your class called HelloWorldAction or
HelloWorld? Just pick one and use that as your Java file name and the
class name.

3. result name=none: Usually result is success but I guess you
could actually return ActionSupport.NONE in your action but I get a
feeling you're not doing that either.

Zarar


On 10/18/07, Ádamo Azambuja [EMAIL PROTECTED] wrote:
  i Have this problem and i lost 2 days trying do fix, what can i do in this
 case?

 I use java 1.4.2 / Struts 2 J4 / Hibernate and Spring.

 i have the HelloWorld.java in the src and src/action to test.


 *struts.xml *
 include file=struts-default.xml/

 constant name=struts.objectFactory value=
 org.apache.struts2.spring.StrutsSpringObjectFactory /

 constant name=struts.devMode value=true /
 package name=action extends=struts-default
 action name=HelloWorld class=HelloWorld
 result name=none/HelloWorld.jsp/result
 /action
 /package

 *applicationContext.xml *
 bean class=
 org.springframework.orm.hibernate3.support.OpenSessionInViewFilter /
 bean id=helloWorld
 class=HelloWorldAction singleton=false
 /bean

 *web.xml *
 filter
 filter-nameSpring OpenEntityManagerInViewFilter/filter-name
 filter-class
 org.springframework.orm.hibernate3.support.OpenSessionInViewFilter
 /filter-class
 /filter
 filter-mapping
 filter-nameSpring OpenEntityManagerInViewFilter/filter-name
 url-pattern/*/url-pattern
 /filter-mapping
 filter
 filter-name struts/filter-name
 filter-classorg.apache.struts2.dispatcher.FilterDispatcher/filter-c lass

 /filter
 filter-mapping
 filter-namestruts/filter-name
 url-pattern/*/url-pattern
 /filter-mapping

 --
 Ádamo B. Azambuja
 JEE Developer
 icq: 112102893
 msn: [EMAIL PROTECTED]
 E-Mail 1: [EMAIL PROTECTED]
 E-Mail 2: [EMAIL PROTECTED]


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



Jasper basic issue (with websphere?)

2007-10-18 Thread j alex
Hi,

I just started using the S2 - Jasper plugin ; new to Jasper as well ; but
not able to get a simple report to show.

Below is my struts xml entry :

package name=cap-default
extends=struts-default,jasperreports-default

action name=newapp class=com.mypage.TestAction
  result name=success type=jasper
   param name=location/jasper_compiled.jasper/param
   param name=dataSourceds/param
   param name=formatPDF/param
 /result
/action
/package

and in TestAction :

JREmptyDataSource ds = new JREmptyDataSource();
return SUCCESS;

The jasper_compiled.jasper is a compiled report (generated using a
standalone Java program) in WebContent.

The console trace is :

[10/18/07 11:23:20:839 EDT] 002e ValueStackDat W
org.apache.commons.logging.impl.Jdk14Logger warn Data source value for data
source ds was null
[10/18/07 11:23:22:742 EDT] 002e ServiceLogger I
com.ibm.ws.ffdc.IncidentStreamImpl initialize FFDC0009I: FFDC opened
incident stream file
d:\IRAD\SDP70\runtimes\base_v61\profiles\AppSrv03\logs\ffdc\server1_76007600_07.10.18_11.23.22_0.txt
[10/18/07 11:23:22:812 EDT] 002e ServiceLogger I
com.ibm.ws.ffdc.IncidentStreamImpl resetIncidentStream FFDC0010I: FFDC
closed incident stream file
d:\IRAD\SDP70\runtimes\base_v61\profiles\AppSrv03\logs\ffdc\server1_76007600_07.10.18_11.23.22_0.txt
[10/18/07 11:23:22:822 EDT] 002e SRTServletRes W   WARNING: Cannot set
status. Response already committed.
[10/18/07 11:23:22:822 EDT] 002e SRTServletRes W   WARNING: Cannot set
header. Response already committed.
[10/18/07 11:23:22:903 EDT] 002e ServiceLogger I
com.ibm.ws.ffdc.IncidentStreamImpl open FFDC0009I: FFDC opened incident
stream file
d:\IRAD\SDP70\runtimes\base_v61\profiles\AppSrv03\logs\ffdc\server1_76007600_07.10.18_11.23.22_1.txt
[10/18/07 11:23:23:003 EDT] 002e ServiceLogger I
com.ibm.ws.ffdc.IncidentStreamImpl resetIncidentStream FFDC0010I: FFDC
closed incident stream file
d:\IRAD\SDP70\runtimes\base_v61\profiles\AppSrv03\logs\ffdc\server1_76007600_07.10.18_11.23.22_1.txt
[10/18/07 11:23:23:003 EDT] 002e WebAppA   SRVE0180I:
[JasperDemoEAR#JasperDemo.war] [/JasperDemo] [Servlet.LOG]: Error page
exception  The server cannot use the error page specified for your
application because of the exception printed below.
[10/18/07 11:23:23:003 EDT] 002e WebAppA   SRVE0181I:
[JasperDemoEAR#JasperDemo.war] [/JasperDemo] [Servlet.LOG]: Error Page
Exception: : com.ibm.ws.webcontainer.webapp.WebAppErrorReport:
at com.ibm.ws.webcontainer.webapp.WebApp.sendError(WebApp.java:2746)
at
com.ibm.ws.webcontainer.extension.DefaultExtensionProcessor.handleRequest(
DefaultExtensionProcessor.java:601)
at
com.ibm.ws.wswebcontainer.extension.DefaultExtensionProcessor.handleRequest(
DefaultExtensionProcessor.java:111)
at com.ibm.ws.webcontainer.webapp.WebApp.handleRequest(WebApp.java:3129)
at com.ibm.ws.webcontainer.webapp.WebGroup.handleRequest(WebGroup.java
:238)
at com.ibm.ws.webcontainer.WebContainer.handleRequest(WebContainer.java
:811)
at com.ibm.ws.wswebcontainer.WebContainer.handleRequest(
WebContainer.java:1433)
at com.ibm.ws.webcontainer.channel.WCChannelLink.ready(
WCChannelLink.java:93)
at
com.ibm.ws.http.channel.inbound.impl.HttpInboundLink.handleDiscrimination(
HttpInboundLink.java:465)
at
com.ibm.ws.http.channel.inbound.impl.HttpInboundLink.handleNewInformation(
HttpInboundLink.java:394)
at com.ibm.ws.http.channel.inbound.impl.HttpInboundLink.ready(
HttpInboundLink.java:274)
at
com.ibm.ws.tcp.channel.impl.NewConnectionInitialReadCallback.sendToDiscriminators
(NewConnectionInitialReadCallback.java:214)
at com.ibm.ws.tcp.channel.impl.NewConnectionInitialReadCallback.complete
(NewConnectionInitialReadCallback.java:113)
at com.ibm.ws.tcp.channel.impl.AioReadCompletionListener.futureCompleted
(AioReadCompletionListener.java:152)
at com.ibm.io.async.AbstractAsyncFuture.invokeCallback(
AbstractAsyncFuture.java:213)
at com.ibm.io.async.AbstractAsyncFuture.fireCompletionActions(
AbstractAsyncFuture.java:195)
at com.ibm.io.async.AsyncFuture.completed(AsyncFuture.java:136)
at com.ibm.io.async.ResultHandler.complete(ResultHandler.java:194)
at com.ibm.io.async.ResultHandler.runEventProcessingLoop(
ResultHandler.java:741)
at com.ibm.io.async.ResultHandler$2.run(ResultHandler.java:863)
at com.ibm.ws.util.ThreadPool$Worker.run(ThreadPool.java:1510)
Caused by: com.ibm.ws.webcontainer.srt.WriteBeyondContentLengthException
at com.ibm.wsspi.webcontainer.util.BufferedServletOutputStream.print(
BufferedServletOutputStream.java:369)
at javax.servlet.ServletOutputStream.println(ServletOutputStream.java
:286)
at com.ibm.ws.webcontainer.webapp.WebApp.sendError(WebApp.java:2682)
... 20 more


I'm not sure if this is a websphere specific issue since all the messages
are coming from 

Re: struts There is no Action mapped for namespace / and action name

2007-10-18 Thread Ádamo Azambuja
i put the log4j and my problem now is this:


13:31:21,484 DEBUG XmlConfigurationProvider:873 - Loaded action
configuration from: struts-plugin.xml
13:31:21,484  INFO XmlConfigurationProvider:140 - Parsing configuration file
[struts-plugin.xml]
StandardContext[/fiergs]Exception starting filter struts
Unable to load bean: type:com.opensymphony.xwork2.ObjectFactory class:
org.apache.struts2.spring.StrutsSpringObjectFactory - bean -
jar:file:/C:/projetos/Fiergs/WebContent/WEB-INF/lib/struts2-
spring-plugin-2.0.9.jar!/struts-plugin.xml:8:132
at
com.opensymphony.xwork2.config.providers.XmlConfigurationProvider.register(
XmlConfigurationProvider.java:208)
at org.apache.struts2.config.StrutsXmlConfigurationProvider.register(
StrutsXmlConfigurationProvider.java:101)
at com.opensymphony.xwork2.config.impl.DefaultConfiguration.reload(
DefaultConfiguration.java:131)
at com.opensymphony.xwork2.config.ConfigurationManager.getConfiguration(
ConfigurationManager.java:52)
at org.apache.struts2.dispatcher.Dispatcher.init_PreloadConfiguration(
Dispatcher.java:395)
at org.apache.struts2.dispatcher.Dispatcher.init(Dispatcher.java:452)
at org.apache.struts2.dispatcher.FilterDispatcher.init(
FilterDispatcher.java:201)
at org.apache.catalina.core.ApplicationFilterConfig.getFilter(
ApplicationFilterConfig.java:225)
at org.apache.catalina.core.ApplicationFilterConfig.setFilterDef(
ApplicationFilterConfig.java:308)


2007/10/18, Zarar Siddiqi [EMAIL PROTECTED]:

 Problems that I see:

 1. Spring bean is defined as helloWorld but referred to as
 HelloWorld in Struts config (case is incorrect).

 2. You're saying that your action class is under src/action so I would
 think the fully qualified name of the class might be
 action.HelloWorldAction but that's now how you're referring to it in
 the Spring config.  Also, is your class called HelloWorldAction or
 HelloWorld? Just pick one and use that as your Java file name and the
 class name.

 3. result name=none: Usually result is success but I guess you
 could actually return ActionSupport.NONE in your action but I get a
 feeling you're not doing that either.

 Zarar


 On 10/18/07, Ádamo Azambuja [EMAIL PROTECTED] wrote:
   i Have this problem and i lost 2 days trying do fix, what can i do in
 this
  case?
 
  I use java 1.4.2 / Struts 2 J4 / Hibernate and Spring.
 
  i have the HelloWorld.java in the src and src/action to test.
 
 
  *struts.xml *
  include file=struts-default.xml/
 
  constant name=struts.objectFactory value=
  org.apache.struts2.spring.StrutsSpringObjectFactory /
 
  constant name=struts.devMode value=true /
  package name=action extends=struts-default
  action name=HelloWorld class=HelloWorld
  result name=none/HelloWorld.jsp/result
  /action
  /package
 
  *applicationContext.xml *
  bean class=
  org.springframework.orm.hibernate3.support.OpenSessionInViewFilter /
  bean id=helloWorld
  class=HelloWorldAction singleton=false
  /bean
 
  *web.xml *
  filter
  filter-nameSpring OpenEntityManagerInViewFilter/filter-name
  filter-class
  org.springframework.orm.hibernate3.support.OpenSessionInViewFilter
  /filter-class
  /filter
  filter-mapping
  filter-nameSpring OpenEntityManagerInViewFilter/filter-name
  url-pattern/*/url-pattern
  /filter-mapping
  filter
  filter-name struts/filter-name
  filter-classorg.apache.struts2.dispatcher.FilterDispatcher/filter-c
 lass
 
  /filter
  filter-mapping
  filter-namestruts/filter-name
  url-pattern/*/url-pattern
  /filter-mapping
 
  --
  Ádamo B. Azambuja
  JEE Developer
  icq: 112102893
  msn: [EMAIL PROTECTED]
  E-Mail 1: [EMAIL PROTECTED]
  E-Mail 2: [EMAIL PROTECTED]
 

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




-- 
Ádamo B. Azambuja
JEE Developer
icq: 112102893
msn: [EMAIL PROTECTED]
E-Mail 1: [EMAIL PROTECTED]
E-Mail 2: [EMAIL PROTECTED]


s:tree and Hibernate

2007-10-18 Thread Cosmin Stanciu
Hi! 
I have been trying for a week now to populate one s:tree with the data from a 
database table but with no luck . I would really apreciate some guidance in how 
to write the ShowDynamicTreeAction class that sends the date to the tree.

I'm using Hibernate DAO to receive the data from my database table and it looks 
like this.
Category: id, name, parent_category_id (from a a recursive 1:n relation to the 
same table using the id).
The Hibernate generated object (Category.java) has the fallowing fields: 
private Integer id;
private Category category;
private String name;
private Set categories = new HashSet(0);

In the CategoryDAO class I have all the methods needed to retreive data from 
the table:
- Category findById(int Id), List findById(int Id), List findParents() and I 
can add any needed method...

My struts.xml has a reference to the class showDynamicTreeAction:
action name=showDynamicTreeAction 
class=struts2.ShowDynamicTreeAction
result/jsp/CategoryList.jsp/result
/action

I'm sure that helping solving this issue would be of much interest for all 
those that intend to use s:tree in their application, as there no example or 
help regarding this matter on the internet.

Thanks a lot!
Cosmin



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

Re: s:tree and Hibernate

2007-10-18 Thread Dave Newton
Is the documentation at
http://struts.apache.org/2.0.9/docs/tree.html out of
date? I haven't looked at it in quite awhile now.

d.

--- Cosmin Stanciu [EMAIL PROTECTED] wrote:

 Hi! 
 I have been trying for a week now to populate one
 s:tree with the data from a database table but
 with no luck . I would really apreciate some
 guidance in how to write the ShowDynamicTreeAction
 class that sends the date to the tree.
 
 I'm using Hibernate DAO to receive the data from my
 database table and it looks like this.
 Category: id, name, parent_category_id (from a a
 recursive 1:n relation to the same table using the
 id).
 The Hibernate generated object (Category.java) has
 the fallowing fields: 
 private Integer id;
 private Category category;
 private String name;
 private Set categories = new HashSet(0);
 
 In the CategoryDAO class I have all the methods
 needed to retreive data from the table:
 - Category findById(int Id), List findById(int Id),
 List findParents() and I can add any needed
 method...
 
 My struts.xml has a reference to the class
 showDynamicTreeAction:
 action name=showDynamicTreeAction
 class=struts2.ShowDynamicTreeAction
 result/jsp/CategoryList.jsp/result
 /action
 
 I'm sure that helping solving this issue would be of
 much interest for all those that intend to use
 s:tree in their application, as there no example or
 help regarding this matter on the internet.
 
 Thanks a lot!
 Cosmin
 
 
 
 __
 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]



Re: s:tree and Hibernate

2007-10-18 Thread Cosmin Stanciu
Hello! Thanks for the supper fast answer!
No it's not! But This section of the documentation is a work-in-progress; more 
to follow. and on the Action tab the funtionality is not shown. :(
I know how to set the getters and setters but don't know how to match the data 
from hibernate with the one needed by the s:tree :

public class ShowTreeAction {
private Category _rootNode;  // Top-level tree node.
// what's next?

}

Thank you!
Cosmin



- Original Message 
From: Dave Newton [EMAIL PROTECTED]
To: Struts Users Mailing List user@struts.apache.org
Sent: Thursday, October 18, 2007 6:22:39 PM
Subject: Re: s:tree and Hibernate


Is the documentation at
http://struts.apache.org/2.0.9/docs/tree.html out of
date? I haven't looked at it in quite awhile now.

d.

--- Cosmin Stanciu [EMAIL PROTECTED] wrote:

 Hi! 
 I have been trying for a week now to populate one
 s:tree with the data from a database table but
 with no luck . I would really apreciate some
 guidance in how to write the ShowDynamicTreeAction
 class that sends the date to the tree.
 
 I'm using Hibernate DAO to receive the data from my
 database table and it looks like this.
 Category: id, name, parent_category_id (from a a
 recursive 1:n relation to the same table using the
 id).
 The Hibernate generated object (Category.java) has
 the fallowing fields: 
 private Integer id;
 private Category category;
 private String name;
 private Set categories = new HashSet(0);
 
 In the CategoryDAO class I have all the methods
 needed to retreive data from the table:
 - Category findById(int Id), List findById(int Id),
 List findParents() and I can add any needed
 method...
 
 My struts.xml has a reference to the class
 showDynamicTreeAction:
 action name=showDynamicTreeAction
 class=struts2.ShowDynamicTreeAction
 result/jsp/CategoryList.jsp/result
 /action
 
 I'm sure that helping solving this issue would be of
 much interest for all those that intend to use
 s:tree in their application, as there no example or
 help regarding this matter on the internet.
 
 Thanks a lot!
 Cosmin
 
 
 
 __
 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]






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

Struts 2 j4 and spring Error

2007-10-18 Thread Ádamo Azambuja
When i use this configuration on my web.xml:
constant name=struts.objectFactory value=
org.apache.struts2.spring.StrutsSpringObjectFactory /
i have the struts2-spring-plugin-2.0.9.jar in my classpath.

i have this error:
14:46:50,246  INFO XmlConfigurationProvider:140 - Parsing configuration file
[struts-plugin.xml]
StandardContext[/strutsBlank]Exception starting filter struts2
Unable to load bean: type:com.opensymphony.xwork2.ObjectFactory class:
org.apache.struts2.spring.StrutsSpringObjectFactory - bean -
jar:file:/C:/projetos/struts2-blank-2.0.9/WebContent/WEB-INF/lib/struts2-
spring-plugin-2.0.9.jar!/struts-plugin.xml:8:132
at
com.opensymphony.xwork2.config.providers.XmlConfigurationProvider.register(
XmlConfigurationProvider.java:208)
at org.apache.struts2.config.StrutsXmlConfigurationProvider.register(
StrutsXmlConfigurationProvider.java:101)


Re: How to improve dojo performance in Struts 2.0.9

2007-10-18 Thread Martin Gainty
Here is what I found

you need the custom-rhino.jar size=715,901 to start with located on your
(system)classpath

now run the ant targets individually

cd buildscripts
ant -Dprofile=struts2 -Dstrip_and_compress=true
cleanant -Dprofile=struts2 -Dstrip_and_compress=true release Note that you
will need to execute the (java)script illustrated here  script
language=javascriptBUT if you dont have Bean Scripting Framework bsf.jar
(size is 175,348) in your classpath nothing will workdespite documentation
for ANT 1.70 (latest) classpath/classpathref attribute cannot be parsed by
script from ANT 1.70 the workaround is to take your BSF.jar and copy to
%ANT_HOME%/libant -Dprofile=struts2 -Dstrip_and_compress=true intern-strings
ant -Dprofile=struts2 -Dstrip_and_compress=true strip-resource-commentsGET
http://localhost:8080/struts2-showcase/struts/dojo/src.js404 (15ms)dojo.js
(line 769)Now when I run the app dojo.js is referencing src.js (
Jeromy/Musachy? )ThanksM--- Original Message -
From: Jeromy Evans [EMAIL PROTECTED]
To: Struts Users Mailing List user@struts.apache.org
Sent: Thursday, October 18, 2007 10:20 AM
Subject: Re: How to improve dojo performance in Struts 2.0.9


 Pedro Herrera wrote:
  It´s not working to me. why don´t you leave yours jars available ?
 
  Herrera
 
 
 Hi Pedro,
 I can't really create a jar for you because its not appropriate to
 extract part of struts out and then redistribute it.  I could create a
 script I suppose, but the problem is mostly solved in struts 2.1 already.

 If you let me know where the instructions fall-short maybe I can help a
 little better?

 regards,
  Jeromy Evans
  Jeromy Evans - Blue Sky Minds wrote:
 
  As suggested, I've added these instructions to the community wiki.
 
 
http://cwiki.apache.org/confluence/display/S2WIKI/Creating+a+custom+Dojo+pro
file+for+Struts+2.0.9
 
 


 -
 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: s:tree and Hibernate

2007-10-18 Thread Dave Newton
--- Cosmin Stanciu [EMAIL PROTECTED] wrote:
 Action tab the funtionality is not shown. :(

Are you filling tree data via Ajax (which the example
on the wiki isn't)?

d.


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



Re: s:tree and Hibernate

2007-10-18 Thread Cosmin Stanciu
Yes! My Jsp file looks exactly like the one provided into the Example 
Applications (struts-2.0.9-apps.zip).
script
function treeNodeSelected(nodeId) {
dojo.io.bind({
url: s:url value='/tags/ui/ajax/dynamicTreeSelectAction.action' 
/?nodeId=+nodeId,
load: function(type, data, evt) {
var displayDiv = dojo.byId(displayId);
displayDiv.innerHTML = data;
},
mimeType: text/html
});
};
dojo.event.topic.subscribe(treeSelected, this, treeNodeSelected);
/script
 

s:tree 
theme=ajax
rootNode=%{treeRootNode} 
childCollectionProperty=children 
nodeIdProperty=id
nodeTitleProperty=name
treeSelectedTopic=treeSelected
/s:tree 

The tree works fine with the data provided in the example application but I 
can't make it work with the data received from my Hibernate layer. So I just 
want to know I should write the ShowDynamicTreeAction.java. 

Thank you!
Cosmin



- Original Message 
From: Dave Newton [EMAIL PROTECTED]
To: Struts Users Mailing List user@struts.apache.org
Sent: Thursday, October 18, 2007 7:27:32 PM
Subject: Re: s:tree and Hibernate

--- Cosmin Stanciu [EMAIL PROTECTED] wrote:
 Action tab the funtionality is not shown. :(

Are you filling tree data via Ajax (which the example
on the wiki isn't)?

d.


---
Hi! 
I have been trying for a week now to populate one s:tree with the data from a 
database table but with no luck . I would really apreciate some guidance in how 
to write the ShowDynamicTreeAction class that sends the date to the tree.

I'm using Hibernate DAO to receive the data from my database table and it looks 
like this.
Category: id, name, parent_category_id (from a a recursive 1:n relation to the 
same table using the id).
The Hibernate generated object (Category.java) has the fallowing fields: 
private Integer id;
private Category category;
private String name;
private Set categories = new HashSet(0);

In the CategoryDAO class I have all the methods needed to retreive data from 
the table:
- Category findById(int Id), List findById(int Id), List findParents() and I 
can add any needed method...

My struts.xml has a reference to the class showDynamicTreeAction:
action name=showDynamicTreeAction 
class=struts2.ShowDynamicTreeAction
result/jsp/CategoryList.jsp/result
/action

I'm sure that helping solving this issue would be of much interest for all 
those that intend to use s:tree in their application, as there no example or 
help regarding this matter on the internet.

Thanks a lot!
Cosmin



-
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 

(beginner) How to intialize a form's input item

2007-10-18 Thread sriharsha . chevuru
Hi,

I am starter in Struts. I am using 1.3.8. 

My requirement: Prepopulate a form feild if value is present.

Can anybody help me in intializing a input feild using struts custom tags?

Thanks

H.


Jstl and struts

2007-10-18 Thread Zhang, Larry (L.)
This might be an old topic, but should we completely rule out using
struts tag and move to jstl tag? If not, does struts have a tag that
will do anything if the filed is equal (1 or 2 or 3 or 4)? Thanks.

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



Annotations and action mappings with !

2007-10-18 Thread Norris Shelton
It appears that this does not work.  Is that correct?  I have 
/employee/employee.action working, but I get a 404 when I try 
/employee/employee.action!list.


 
Norris Shelton
Software Engineer
Sun Certified Java 1.1 Programmer
Shelton Consulting, LLC
ICQ# 26487421
AIM NorrisEShelton
YIM norrisshelton

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

Re: (beginner) How to intialize a form's input item

2007-10-18 Thread Dave Newton
Not helpful for S1.

You're better off pre-populating the ActionForm in the
action (not sure what 1.3 provides for that kind of
functionality) rather than via S1 or JSTL tags.

d.

--- Norris Shelton [EMAIL PROTECTED] wrote:

 Look at the Preparable or Model interface.
 
 
 - Original Message 
 From: [EMAIL PROTECTED]
 [EMAIL PROTECTED]
 To: user@struts.apache.org
 Sent: Thursday, October 18, 2007 1:47:22 PM
 Subject: (beginner) How to intialize a form's input
 item
 
 Hi,
 
 I am starter in Struts. I am using 1.3.8. 
 
 My requirement: Prepopulate a form feild if value is
 present.
 
 Can anybody help me in intializing a input feild
 using struts custom tags?
 
 Thanks
 
 H.
 
 __
 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]



[answer]Re: Annotations and action mappings with !

2007-10-18 Thread Norris Shelton
I found the answer by accident.  The action needs to be specified as 
/employee/employee!list.action.  It is not intuitive, but it does work. 


- Original Message 
From: Norris Shelton [EMAIL PROTECTED]
To: Strutss user@struts.apache.org
Sent: Thursday, October 18, 2007 2:02:45 PM
Subject: Annotations and action mappings with !

It appears that this does not work.  Is that correct?  I have 
/employee/employee.action working, but I get a 404 when I try 
/employee/employee.action!list.



Norris Shelton
Software Engineer
Sun Certified Java 1.1 Programmer
Shelton Consulting, LLC
ICQ# 26487421
AIM NorrisEShelton
YIM norrisshelton

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

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

Re: Annotations and action mappings with !

2007-10-18 Thread Wes Wannemacher
what about /employee!list.action

-W

On 10/18/07, Norris Shelton [EMAIL PROTECTED] wrote:
 It appears that this does not work.  Is that correct?  I have 
 /employee/employee.action working, but I get a 404 when I try 
 /employee/employee.action!list.



 Norris Shelton
 Software Engineer
 Sun Certified Java 1.1 Programmer
 Shelton Consulting, LLC
 ICQ# 26487421
 AIM NorrisEShelton
 YIM norrisshelton

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


-- 
Wesley Wannemacher
President, Head Engineer/Consultant
WanTii, Inc.
http://www.wantii.com

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



Re: Annotations and action mappings with !

2007-10-18 Thread Norris Shelton
Thank you.


- Original Message 
From: Wes Wannemacher [EMAIL PROTECTED]
To: Struts Users Mailing List user@struts.apache.org
Sent: Thursday, October 18, 2007 2:23:43 PM
Subject: Re: Annotations and action mappings with !

what about /employee!list.action

-W

On 10/18/07, Norris Shelton [EMAIL PROTECTED] wrote:
 It appears that this does not work.  Is that correct?  I have 
 /employee/employee.action working, but I get a 404 when I try 
 /employee/employee.action!list.



 Norris Shelton
 Software Engineer
 Sun Certified Java 1.1 Programmer
 Shelton Consulting, LLC
 ICQ# 26487421
 AIM NorrisEShelton
 YIM norrisshelton

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


-- 
Wesley Wannemacher
President, Head Engineer/Consultant
WanTii, Inc.
http://www.wantii.com

-
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 

Re: [s2] select tag not setting parameter

2007-10-18 Thread Marcos Hernandez
You're welcome. I think too that the documentation is lacking of some
detailed examples, but you could contribute with a comment, now that you
know a little more. Go ahead, you are part of the community too ;-)

http://cwiki.apache.org/confluence/display/WW/select

On 10/15/07, Kevin Wade [EMAIL PROTECTED] wrote:

 You, Marcos, (and Laurie) were right: there was not a full list of
 values aside from the county names in the list.  Each entry in the
 list looked something like this:
 option value=ORANGE/option

 So the option value was always empty.  The trick for me was to set
 the listKey parameter to name, which contained the name of the
 county (which i also use for listValue).  Frankly, I guess I just
 didn't understand the documentation -- and what listKey and listValue
 meant and did in this context.  I didn't grok it at first.

 As always, many thanks to the struts 2 community for pointing me in
 the right direction.

 Kevin

 On Oct 12, 2007, at 7:03 PM, Marcos Hernandez wrote:

  Just as a debug thought: what happens when you fill the list
  parameter with
  a couple of counties/value pairs by hand?
 
  On the other hand, does the generated HTML have a full list of
  values aside
  of the counties name list you are looking in the drop-down box?
 
  On 10/12/07, Kevin Wade [EMAIL PROTECTED] wrote:
 
  According to my sniffer, what's sent on the wire looks like this:
  lastName=smithfirstName=johncounty=
 
  which makes sense since the logging output of struts 2 says this:
  com.opensymphony.xwork2.interceptor.ParametersInterceptor - Setting
  params county = [  ] firstName = [ john ] lastName = [ smith ]
 
  So... county is null/empty. But why? Obviously the select tag and the
  form know that I want it to set the county field in my resulting
  action class.  It's handing the lastName and firstName fields
  just fine (via the textfield tags).   Am I doing something wrong in
  the select tag?  The jsp form that displays my list of counties via
  the select tag *looks* right (in that the list of counties -- all
  strings -- looks good).  But, no matter which entry (county) I select
  from the list, no county is being passed on submit.
 
  Any ideas at all what I'm doing wrong?  This is my first attempt at
  using the select tag.  Here's my usage again:
 
  s:form action=search.action
  s:textfield key=search.lastName name=lastName /
  s:textfield key=search.firstName
  name=firstName/
 
  s:select key=search.county
  name=county
  list=counties
  listKey=id
  listValue=name
  size=1
  /
 
  s:submit value=Find align=center /
  /s:form
 
  Again, the form's select tag seems to be grabbing the entries from my
  list (a java.util.List called counties) ok and building a correct
  looking drop-down html select element.  But I can't get the tag to
  set county to... well, anything at all, on submit.
 
  BTW, I'm using 2.0.9.
 
  Kevin
 
 
 
  On Oct 12, 2007, at 4:55 PM, Dave Newton wrote:
 
  What's being sent on the wire? (Like, is there a
  search.county param being sent, etc.)
 
  d.
 
  --- Kevin Wade [EMAIL PROTECTED] wrote:
 
  Bump.  Any one have any ideas at all?  I'm sure I'm
  just doing
  something incorrect w/ the select tag but just can't
  see it.
 
  Kevin
 
  On Oct 8, 2007, at 4:59 PM, Kevin Wade wrote:
 
  I'm having difficulty with a struts 2 form (jsp)
  that includes the
  use of a select tag.  In short, I can't seem to
  get the select tag
  to set the parameter when submitted.
 
  Here's the scenario.  My form (for searching by
  last name, first
  name, and county fields)  looks like this:
 
  s:form action=search.action
  s:textfield key=search.lastName
  name=lastName /
  s:textfield key=search.firstName
  name=firstName/
  s:select key=search.county
  name=county
  list=counties
  listKey=id
  listValue=name
  size=1
  /
  s:submit value=Search align=center /
  /s:form
 
  In the calling action, there is a  List called
  counties with a
  getCounties() method.  So, the input form looks
  right.  There is a
  nice drop-down box w/ a long list of counties.  So
  far, so good.
 
  But, when I submit the form (e.g. first name =
  john, last name =
  smith, county chosen from select drop-down list
  = orange) I get
  nothing in the county field of the search
  action. lastName
  looks fine.  firstName is fine.  But, regardless
  of which item I
  select in the list of counties, the county
  parameter doesn't get
  set.  I definitely have setters for firstName,
  lastName, and
  county  in the search action:
 
  public void setCounty(String county) {
  this.county = county;
  }
 
  In 

Re: (beginner) How to intialize a form's input item

2007-10-18 Thread Norris Shelton
Look at the Preparable or Model interface.


- Original Message 
From: [EMAIL PROTECTED] [EMAIL PROTECTED]
To: user@struts.apache.org
Sent: Thursday, October 18, 2007 1:47:22 PM
Subject: (beginner) How to intialize a form's input item

Hi,

I am starter in Struts. I am using 1.3.8. 

My requirement: Prepopulate a form feild if value is present.

Can anybody help me in intializing a input feild using struts custom tags?

Thanks

H.

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

Re: Struts 2 j4 and spring Error

2007-10-18 Thread Ed Knutson
I also have noticed some classloading issues with the j4 distro.  In my
case, WebSphere 6.0 is not able to load a retrotranslated version of the
sitemesh plugin.  I think in your case, the preferred method of
integrating Spring is to put the following line in struts.properties
(this file is searched for as a resource in the classpath, e.g.
/WEB-INF/classes/struts.properties):

struts.objectFactory=spring

You should not need to put a constant element in web.xml if you do that
instead.  I'm actually not entirely sure that is needed either, as I
remember seeing somewhere that Spring is already the default IoC
container for Webwork 2, and that may apply to Struts 2 as well.  If it
is working, you should see a line in your SystemOut.log about
initializing Spring integration.  Hope all that helps.


 Ádamo Azambuja [EMAIL PROTECTED] 10/18/07 11:51 AM 
When i use this configuration on my web.xml:
constant name=struts.objectFactory value=
org.apache.struts2.spring.StrutsSpringObjectFactory /
i have the struts2-spring-plugin-2.0.9.jar in my classpath.

i have this error:
14:46:50,246  INFO XmlConfigurationProvider:140 - Parsing configuration
file
[struts-plugin.xml]
StandardContext[/strutsBlank]Exception starting filter struts2
Unable to load bean: type:com.opensymphony.xwork2.ObjectFactory class:
org.apache.struts2.spring.StrutsSpringObjectFactory - bean -
jar:file:/C:/projetos/struts2-blank-2.0.9/WebContent/WEB-INF/lib/struts2-
spring-plugin-2.0.9.jar!/struts-plugin.xml:8:132
at
com.opensymphony.xwork2.config.providers.XmlConfigurationProvider.register(
XmlConfigurationProvider.java:208)
at
org.apache.struts2.config.StrutsXmlConfigurationProvider.register(
StrutsXmlConfigurationProvider.java:101)


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



RE: (beginner) How to intialize a form's input item

2007-10-18 Thread Slattery, Tim - BLS
 My requirement: Prepopulate a form feild if value is present.
 
 Can anybody help me in intializing a input feild using struts 
 custom tags?

The tags look for a corresponding property in the form bean, and take an
initial value from that. For example, if this tag is in you JSP file:

html:text property=name/

Struts will call the getter method String getName() in your form bean.
Whatever that method returns will be the starting value in the text box.

--
Tim Slattery
[EMAIL PROTECTED]


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



RE: (beginner) How to intialize a form's input item

2007-10-18 Thread sriharsha . chevuru
It doesn't seem to work. I am not getting the value which I am setting in 
TestAction.java in the ActionForm.jsp. Here is what i did, (its a test 
app), Please have a look at it and correct me:

struts_config.xml

struts-config
form-beans
form-bean
name=processForm
type=app.ProcessForm/

   /form-beans

global-forwards
forward
name=welcome
path=/Welcome.do/
/global-forwards

action-mappings
action
path=/Welcome  type=app.TestAction
name=processForm
validate=false
forward name=test path=/pages/AcceptForm.jsp
/
/action
action
path=/ProcessAction
type=app.ProcessAction
name=processForm
scope=session
validate=false
input=/pages/Input.jsp
forward name=end path=/pages/End.jsp/
/action
action
path=/Page1Action
parameter=/pages/End.jsp
type=org.apache.struts.action.ForwardAction/
 
/action-mappings
message-resources parameter=MessageResources /

plug-in className=org.apache.struts.tiles.TilesPlugin 
  set-property property=definitions-config
   value=/WEB-INF/tiles-defs.xml /
  set-property property=moduleAware value=true /
  set-property property=definitions-parser-validate value=true /
/plug-in

  plug-in className=org.apache.struts.validator.ValidatorPlugIn
set-property
property=pathnames
value=/org/apache/struts/validator/validator-rules.xml,
   /WEB-INF/validation.xml/
  /plug-in
/struts-config

ProcessForm.java

public class ProcessForm extends ActionForm {
private String salutation;
private String name;
private String username;
private String password;
private String email;
static final long serialVersionUID = 1;
 
public String getEmail() {
return email;
}
public void setEmail(String email) {
this.email = email;
}
public String getName() {
return name;
}
public void setName(String name) {
this.name = name;
}
public String getPassword() {
return password;
}
public void setPassword(String password) {
this.password = password;
}
public String getSalutation() {
return salutation;
}
public void setSalutation(String salutation) {
this.salutation = salutation;
}
public String getUsername() {
return username;
}
public void setUsername(String username) {
this.username = username;
}
}

TestAction.java

public class TestAction extends Action {

public ActionForward execute(ActionMapping arg0, ActionForm arg1, 
HttpServletRequest arg2, HttpServletResponse arg3) throws Exception {
ProcessForm processForm = new ProcessForm();
processForm.setUsername(Its Successful);
return arg0.findForward(test);
} 
}

AcceptForm.jsp

%@ taglib uri=struts-html prefix=html %

html
head
titleStart Page/title
/head
body
h2Trial Form/h2
html:form action=/ProcessAction
User Name: html:text property=username/br/
Password: html:password property=password/br/
Email: html:text property=email/br/
html:submit value=Submit/
/html:form
/body
/html

Thank you
-H



Slattery, Tim - BLS [EMAIL PROTECTED] 
10/18/2007 11:55 AM

Please respond to
Struts Users Mailing List user@struts.apache.org


To
Struts Users Mailing List user@struts.apache.org
cc

Subject
RE: (beginner) How to intialize a form's input item






 My requirement: Prepopulate a form feild if value is present.
 
 Can anybody help me in intializing a input feild using struts 
 custom tags?

The tags look for a corresponding property in the form bean, and take an
initial value from that. For example, if this tag is in you JSP file:

html:text property=name/

Struts will call the getter method String getName() in your form bean.
Whatever that method returns will be the starting value in the text box.

--
Tim Slattery
[EMAIL PROTECTED]


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


ForwardSourceID:NTD736 


RE: s:tree and Hibernate

2007-10-18 Thread Engelking, Nicholas
I just went through the same thing. In struts 2.1 there is a new href attribute 
on the tree tag. It points to an action that returns some json using the json 
plugin that gives all the info about the node. You should be able to use it in 
Struts 2.0.9 as well by using the dew dojo plugin and by using the json plugin. 
My code looks like this:

In my jsp I add a reference to the struts dojo tags in the new dojo plugin:

%@ taglib prefix=s uri=/struts-tags%
%@ taglib prefix=sx uri=/struts-dojo-tags%

...
s:url var=treeUrl action=treeLookup /
sx:tree href=%{#treeUrl} /


My action configuration for treeLookup is in a package extending json-default, 
to allow me to return json:

package name=eqd namespace=/ extends=json-default

...

action name=treeLookup
class=org.tds.eqd.website.actions.usermanager.UserManagerAction
result type=json
param name=rootoptions/param
/result
/action

/package

Note that I made the root of my json the options parameter of my action. The 
options parameter gets turned into json automatically and gets sent back to the 
client.

The tree will call the treeLookup action passing a parameter called nodeId. 
When it's null, you return the root node. Otherwise return the children for the 
node passed.

public class UserManagerAction {

private String nodeId;
public String getNodeId() {
return nodeId;
}

public void setNodeId(String nodeId) {
this.nodeId = nodeId;
}
public CollectionTreeBean getOptions() {
...
}
}

public class TreeBean {
private final boolean hasChildren;
private final String id;
private final String label;

public TreeBean(boolean hasChildren, String id, String label) {
this.hasChildren = hasChildren;
this.id = id;
this.label = label;
}
public boolean isHasChildren() {
return hasChildren;
}
public String getId() {
return id;
}
public String getLabel() {
return label;
}
}

In the getOptions method you send back a collection of beans that have a label, 
an id, and whether or not they have children.

You could look up the node in hibernate using the id, then iterate over that 
nodes children and create beans for them.

The final format for the json should look something like:


[
 {
label: text of node1,
id: id1,
hasChildren: true
 },
 {
label: text of node2,
id: id2,
hasChildren: false
 }
]

See https://issues.apache.org/struts/browse/WW-1910 for more info. Remember to 
put the json and dojo plugins in you lib directory.


-Original Message-
From: Cosmin Stanciu [mailto:[EMAIL PROTECTED]
Sent: October 18, 2007 1:50 PM
To: Struts Users Mailing List
Subject: Re: s:tree and Hibernate

Yes! My Jsp file looks exactly like the one provided into the Example 
Applications (struts-2.0.9-apps.zip).
script
function treeNodeSelected(nodeId) {
dojo.io.bind({
url: s:url value='/tags/ui/ajax/dynamicTreeSelectAction.action' 
/?nodeId=+nodeId,
load: function(type, data, evt) {
var displayDiv = dojo.byId(displayId);
displayDiv.innerHTML = data;
},
mimeType: text/html
});
};
dojo.event.topic.subscribe(treeSelected, this, treeNodeSelected);
/script


s:tree
theme=ajax
rootNode=%{treeRootNode}
childCollectionProperty=children
nodeIdProperty=id
nodeTitleProperty=name
treeSelectedTopic=treeSelected
/s:tree

The tree works fine with the data provided in the example application but I 
can't make it work with the data received from my Hibernate layer. So I just 
want to know I should write the ShowDynamicTreeAction.java.

Thank you!
Cosmin



- Original Message 
From: Dave Newton [EMAIL PROTECTED]
To: Struts Users Mailing List user@struts.apache.org
Sent: Thursday, October 18, 2007 7:27:32 PM
Subject: Re: s:tree and Hibernate

--- Cosmin Stanciu [EMAIL PROTECTED] wrote:
 Action tab the funtionality is not shown. :(

Are you filling tree data via Ajax (which the example
on the wiki isn't)?

d.


---
Hi!
I have been trying for a week now to populate one s:tree with the data from a 
database table but with no luck . I would really apreciate some guidance in how 
to write the ShowDynamicTreeAction class that sends the date to the tree.

I'm using Hibernate DAO to receive the data from my database table and it looks 
like this.
Category: id, name, parent_category_id (from a a recursive 1:n relation to the 
same table using the id).
The Hibernate generated object (Category.java) has the fallowing fields:
private Integer id;
private Category category;
private String name;
private Set categories = new HashSet(0);

In the CategoryDAO class I have all the methods needed to 

RE: (beginner) How to intialize a form's input item

2007-10-18 Thread Dave Newton
You're creating a new ActionForm instead of using the
one provided to you.

--- [EMAIL PROTECTED] wrote:

 It doesn't seem to work. I am not getting the value
 which I am setting in 
 TestAction.java in the ActionForm.jsp. Here is what
 i did, (its a test 
 app), Please have a look at it and correct me:
 
 struts_config.xml
 
 struts-config
 form-beans
 form-bean
 name=processForm
 type=app.ProcessForm/
 
/form-beans
 
 global-forwards
 forward
 name=welcome
 path=/Welcome.do/
 /global-forwards
 
 action-mappings
 action
 path=/Welcome  type=app.TestAction
 name=processForm
 validate=false
 forward name=test
 path=/pages/AcceptForm.jsp
 /
 /action
 action
 path=/ProcessAction
 type=app.ProcessAction
 name=processForm
 scope=session
 validate=false
 input=/pages/Input.jsp
 forward name=end
 path=/pages/End.jsp/
 /action
 action
 path=/Page1Action
 parameter=/pages/End.jsp

 type=org.apache.struts.action.ForwardAction/
  
 /action-mappings
 message-resources parameter=MessageResources
 /
 
 plug-in
 className=org.apache.struts.tiles.TilesPlugin 
   set-property property=definitions-config
   
 value=/WEB-INF/tiles-defs.xml /
   set-property property=moduleAware
 value=true /
   set-property
 property=definitions-parser-validate value=true
 /
 /plug-in
 
   plug-in

className=org.apache.struts.validator.ValidatorPlugIn
 set-property
 property=pathnames


value=/org/apache/struts/validator/validator-rules.xml,
/WEB-INF/validation.xml/
   /plug-in
 /struts-config
 
 ProcessForm.java
 
 public class ProcessForm extends ActionForm {
 private String salutation;
 private String name;
 private String username;
 private String password;
 private String email;
 static final long serialVersionUID = 1;
  
 public String getEmail() {
 return email;
 }
 public void setEmail(String email) {
 this.email = email;
 }
 public String getName() {
 return name;
 }
 public void setName(String name) {
 this.name = name;
 }
 public String getPassword() {
 return password;
 }
 public void setPassword(String password) {
 this.password = password;
 }
 public String getSalutation() {
 return salutation;
 }
 public void setSalutation(String salutation)
 {
 this.salutation = salutation;
 }
 public String getUsername() {
 return username;
 }
 public void setUsername(String username) {
 this.username = username;
 }
 }
 
 TestAction.java
 
 public class TestAction extends Action {
 
 public ActionForward execute(ActionMapping
 arg0, ActionForm arg1, 
 HttpServletRequest arg2, HttpServletResponse arg3)
 throws Exception {
 ProcessForm processForm = new
 ProcessForm();
 processForm.setUsername(Its
 Successful);
 return arg0.findForward(test);
 } 
 }
 
 AcceptForm.jsp
 
 %@ taglib uri=struts-html prefix=html %
 
 html
 head
 titleStart Page/title
 /head
 body
 h2Trial Form/h2
 html:form action=/ProcessAction
 User Name: html:text
 property=username/br/
 Password: html:password
 property=password/br/
 Email: html:text property=email/br/
 html:submit value=Submit/
 /html:form
 /body
 /html
 
 Thank you
 -H
 
 
 
 Slattery, Tim - BLS [EMAIL PROTECTED] 
 10/18/2007 11:55 AM
 
 Please respond to
 Struts Users Mailing List user@struts.apache.org
 
 
 To
 Struts Users Mailing List user@struts.apache.org
 cc
 
 Subject
 RE: (beginner) How to intialize a form's input item
 
 
 
 
 
 
  My requirement: Prepopulate a form feild if value
 is present.
  
  Can anybody help me in intializing a input feild
 using struts 
  custom tags?
 
 The tags look for a corresponding property in the
 form bean, and take an
 initial value from that. For example, if this tag is
 in you JSP file:
 
 html:text property=name/
 
 Struts will call the getter method String
 getName() in your form bean.
 Whatever that method returns will be the starting
 value in the text box.
 
 --
 Tim Slattery
 [EMAIL PROTECTED]
 
 
 
=== message truncated ===


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



RE: (beginner) How to intialize a form's input item

2007-10-18 Thread sriharsha . chevuru
Silly one.. Thanks:)



Dave Newton [EMAIL PROTECTED] 
10/18/2007 03:01 PM

Please respond to
Struts Users Mailing List user@struts.apache.org


To
Struts Users Mailing List user@struts.apache.org
cc

Subject
RE: (beginner) How to intialize a form's input item






You're creating a new ActionForm instead of using the
one provided to you.

--- [EMAIL PROTECTED] wrote:

 It doesn't seem to work. I am not getting the value
 which I am setting in 
 TestAction.java in the ActionForm.jsp. Here is what
 i did, (its a test 
 app), Please have a look at it and correct me:
 
 struts_config.xml
 
 struts-config
 form-beans
 form-bean
 name=processForm
 type=app.ProcessForm/
 
/form-beans
 
 global-forwards
 forward
 name=welcome
 path=/Welcome.do/
 /global-forwards
 
 action-mappings
 action
 path=/Welcome  type=app.TestAction
 name=processForm
 validate=false
 forward name=test
 path=/pages/AcceptForm.jsp
 /
 /action
 action
 path=/ProcessAction
 type=app.ProcessAction
 name=processForm
 scope=session
 validate=false
 input=/pages/Input.jsp
 forward name=end
 path=/pages/End.jsp/
 /action
 action
 path=/Page1Action
 parameter=/pages/End.jsp
 
 type=org.apache.struts.action.ForwardAction/
 
 /action-mappings
 message-resources parameter=MessageResources
 /
 
 plug-in
 className=org.apache.struts.tiles.TilesPlugin 
   set-property property=definitions-config
 
 value=/WEB-INF/tiles-defs.xml /
   set-property property=moduleAware
 value=true /
   set-property
 property=definitions-parser-validate value=true
 /
 /plug-in
 
   plug-in

className=org.apache.struts.validator.ValidatorPlugIn
 set-property
 property=pathnames
 

value=/org/apache/struts/validator/validator-rules.xml,
/WEB-INF/validation.xml/
   /plug-in
 /struts-config
 
 ProcessForm.java
 
 public class ProcessForm extends ActionForm {
 private String salutation;
 private String name;
 private String username;
 private String password;
 private String email;
 static final long serialVersionUID = 1;
 
 public String getEmail() {
 return email;
 }
 public void setEmail(String email) {
 this.email = email;
 }
 public String getName() {
 return name;
 }
 public void setName(String name) {
 this.name = name;
 }
 public String getPassword() {
 return password;
 }
 public void setPassword(String password) {
 this.password = password;
 }
 public String getSalutation() {
 return salutation;
 }
 public void setSalutation(String salutation)
 {
 this.salutation = salutation;
 }
 public String getUsername() {
 return username;
 }
 public void setUsername(String username) {
 this.username = username;
 }
 }
 
 TestAction.java
 
 public class TestAction extends Action {
 
 public ActionForward execute(ActionMapping
 arg0, ActionForm arg1, 
 HttpServletRequest arg2, HttpServletResponse arg3)
 throws Exception {
 ProcessForm processForm = new
 ProcessForm();
 processForm.setUsername(Its
 Successful);
 return arg0.findForward(test);
 } 
 }
 
 AcceptForm.jsp
 
 %@ taglib uri=struts-html prefix=html %
 
 html
 head
 titleStart Page/title
 /head
 body
 h2Trial Form/h2
 html:form action=/ProcessAction
 User Name: html:text
 property=username/br/
 Password: html:password
 property=password/br/
 Email: html:text property=email/br/
 html:submit value=Submit/
 /html:form
 /body
 /html
 
 Thank you
 -H
 
 
 
 Slattery, Tim - BLS [EMAIL PROTECTED] 
 10/18/2007 11:55 AM
 
 Please respond to
 Struts Users Mailing List user@struts.apache.org
 
 
 To
 Struts Users Mailing List user@struts.apache.org
 cc
 
 Subject
 RE: (beginner) How to intialize a form's input item
 
 
 
 
 
 
  My requirement: Prepopulate a form feild if value
 is present.
 
  Can anybody help me in intializing a input feild
 using struts 
  custom tags?
 
 The tags look for a corresponding property in the
 form bean, and take an
 initial value from that. For example, if this tag is
 in you JSP file:
 
 html:text property=name/
 
 Struts will call the getter method String
 getName() in your form bean.
 Whatever that method returns will be the starting
 value in the text box.
 
 --
 Tim Slattery
 [EMAIL PROTECTED]
 
 
 
=== message truncated ===



the isapi rewrite

2007-10-18 Thread Fencer
As a web page like .aspx rewritten to the same name with .html suffix, if
the html page does exist I want to response the html rather than the aspx,
how could I do with this?

I think it is sth about level
example:

a.aspx to a.html

if a.html itselft does not exist, I hope the server response the a.aspx as
a.html; if a.html DOES EXIST on the server, I just hope the server response
the a.html instead of calling the rewrite module.

I need your help

 

Regards



Re: How to improve dojo performance in Struts 2.0.9

2007-10-18 Thread Andre Prasetya
Any dates for 2.1.x release ? I just tried struts 2.0.9 and i like it 
very much, feature that i need most is the ajax validation which is only 
at 2.1.x CMIIW


-Andre-

Jeromy Evans wrote:

Pedro Herrera wrote:

It´s not working to me. why don´t you leave yours jars available ?

Herrera

  

Hi Pedro,
I can't really create a jar for you because its not appropriate to 
extract part of struts out and then redistribute it.  I could create a 
script I suppose, but the problem is mostly solved in struts 2.1 already.


If you let me know where the instructions fall-short maybe I can help 
a little better?


regards,
Jeromy Evans



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



Images

2007-10-18 Thread Prashant Desai

I have some images displayed on my website... the images on the first page do 
not get loaded when the page displays for the first time.. you can see it 
here... http://www.hapandharpur.com. there are images in the right top corner. 
One is a logo and one is a symbol.. Both of those images do not get loaded when 
I access the site that is deployed on internet. If I access the local 
code(which is my dev env) it opens fine...
 
what could be the problem??
 
This is the tag that I am using.
 
  logic:present parameter=mName  logic:match value=home 
parameter=mName  br  td valign=top  html:img 
page=/img/handicapped.jpg/  /td  /logic:match  /logic:present
 
Thanks for your help.
 
prashant
_
Peek-a-boo FREE Tricks  Treats for You!
http://www.reallivemoms.com?ocid=TXT_TAGHMloc=us

Images

2007-10-18 Thread Prashant Desai

I have some images displayed on my website... the images on the first page do 
not get loaded when the page displays for the first time.. you can see it 
here... http://www.hapandharpur.com. there are images in the right top corner. 
One is a logo and one is a symbol.. Both of those images do not get loaded when 
I access the site that is deployed on internet. If I access the local 
code(which is my dev env) it opens fine...
 
what could be the problem??
 
This is the tag that I am using.
 
  logic:present parameter=mName  logic:match value=home 
parameter=mName  br  td valign=top  html:img 
page=/img/handicapped.jpg/  /td  /logic:match  /logic:present
 
Thanks for your help.
 
prashant
_
Peek-a-boo FREE Tricks  Treats for You!
http://www.reallivemoms.com?ocid=TXT_TAGHMloc=us