Re: How to access request & session objects in jsp using struts2 tags

2007-08-31 Thread Arup Francis
Oops sorry! yes thats rite... well my requirement was getting the equivalent of <%= request.getParameter("paramname") %> in struts2 using s2 tags alone and for that we have to look into parameters object and not the request object. My understanding was tat since request parameters wud be coming u

Re: Struts 2 !!!OK!!! cannot we live without Spring?

2007-08-31 Thread Musachy Barroso
Plus, if you haven't used Spring, you should give it a try, it rocks, except the MVC, IMO (but I'm biased anyway :) ) musachy On 8/31/07, Dave Newton <[EMAIL PROTECTED]> wrote: > --- Hayrol Reyes Mejía <[EMAIL PROTECTED]> wrote: > > why I have found several documentation, tutorials, > > etc, th

Re: Struts 2 !!!OK!!! cannot we live without Spring?

2007-08-31 Thread Dave Newton
--- Hayrol Reyes Mejía <[EMAIL PROTECTED]> wrote: > why I have found several documentation, tutorials, > etc, that always include Spring? ... It's supposed > that we need to live with Spring for the rest of > the live? You don't need to use Spring if you don't want to. Spring consists of many i

Re: Validation using validation.xml issue

2007-08-31 Thread Ashish Kulkarni
Hi The error is thrown by validator frame work, and hence it never reaches action class where i can load those list again, I am not very sure how validtor framework works Ashish On 8/31/07, Laurie Harper <[EMAIL PROTECTED]> wrote: > > Ashish Kulkarni wrote: > > Hi > > I have a defined following b

Struts 2 !!!OK!!! cannot we live without Spring?

2007-08-31 Thread Hayrol Reyes Mejía
I was recently looking around for the big difference between Struts 1 and Struts 2. And I think that there are bad news for a lot of medium and big Struts1x projects. The good news is that the new Struts is betting to prevail, again, for a new long time. I mean, it's now: easy to build, en

filling arrays in Struts

2007-08-31 Thread Sergio Stateri Jr
Hi all, I?m trying to receive a filled array of objects. In struts-config: In HTML file: When I try to submit a form with these configurations, the following expection is thrown: java.lang.ArrayIndexOutOfBoundsException at java.lang.reflect.Array.get(Native Method)

[S2] ParametersInterceptor & nested indexed collections

2007-08-31 Thread Mark Bargen
Hello, folks, I’d appreciate some direction / input / feedback with a Struts 2 issue involving ParametersInterceptor to set properties directly on my mode where the model contains a multi-level (collections-within-collections) structure. It may very well be that (novice that I am) I’m going about

Re: [s2] custom ExceptionMappingInterceptor log

2007-08-31 Thread johana pin
Thank you for replay. log4j.properties: log4j.rootLogger=DEBUG log4j.logger.cus.util = DEBUG ,R # define the log file name log4j.appender.R=org.apache.log4j.RollingFileAppender log4j.appender.R.File=/IBM/WebSphere/AppServer/profiles/default/logs/server1/CUS.log # Maximum log file size: 1000kb

Re: How to print from 1 to 10 with struts2 tags?

2007-08-31 Thread Musachy Barroso
S2 tags do not provide a "for" tag, but an "iterator" tag, so I don't think you can do it with struts tags (unless you pass something like "%{1,2,3}" in the "value" attribute to the iterator, which defeats the purpose of the "for" tag). As Laurie mentioned, you would have to use JSTL. musachy On

Re: [s2] custom ExceptionMappingInterceptor log

2007-08-31 Thread Laurie Harper
johana pin wrote: Hi, I extended 'ExceptionMappingInterceptor' to add the logging functionality. I want to log to my own file. The problem is that the logging is done in SystemOut file. I used log4j in the custom interceptor: private org.apache.commons.logging.Log log = LogFactory.getLog(getC

Re: How to print from 1 to 10 with struts2 tags?

2007-08-31 Thread Laurie Harper
fergunet wrote: Hi all! I need to paginate some things and it would be useful to have the number of the pages like that: [first/previous] 1,2,3,_4_, 5, 6 [next/last] The _4_ is the actual_page. Yeah, is like the display:table of displaytag but made by myself. I've the stuff between the [] made

Re: Validation using validation.xml issue

2007-08-31 Thread Laurie Harper
Ashish Kulkarni wrote: Hi I have a defined following bean in struts-config.xml In my action class i set datereqList and pass it along to the jsp, the jsp displays it as drop down box, in my validtion.xml i am checking to make sure that color is not blank, So when validation finds that color is

Re: [S2] Where to put hibernate's SessionFactory?

2007-08-31 Thread Kevin Lawrence
I'm a newbie too - so I can't tell you the best way - but what I did is lazily create one and put it in the the application context. Kevin http://www.junitfactory.com Just went live with Struts2 wild_oscar wrote: My question is: what is the most appropriate way of binding the SessionFactory

Validation using validation.xml issue

2007-08-31 Thread Ashish Kulkarni
Hi I have a defined following bean in struts-config.xml In my action class i set datereqList and pass it along to the jsp, the jsp displays it as drop down box, in my validtion.xml i am checking to make sure that color is not blank, So when validation finds that color is blank it send response t

Re: HELP! Could not open connection with host: jakarta.apache.org and port: 80??

2007-08-31 Thread Laurie Harper
This is usually a result of using the wrong DOCTYPE in one of your XML configuration files (in this case, one of /WEB-INF/validator-rules.xml, /WEB-INF/validator-rules-extra.xml, /WEB-INF/validation.xml). Make sure the declared DOCTYPE is appropriate to the version of Struts you're using. Ther

[S2] Where to put hibernate's SessionFactory?

2007-08-31 Thread wild_oscar
I am making my first web app and I found out today I was doing something wrong: I was building a SessionFactory on my HibernateEntityManager: _sessionFactory = configuration.buildSessionFactory(); This EntityManager is called on the action so, basically, I was creating a SessionFactory on each

Re: Unsolved datepicker problem

2007-08-31 Thread vamsi
dojo scripts are getting loaded all the scripts are loading no errors I checked in Mozilla error console - Original Message - From: "Jeromy Evans" <[EMAIL PROTECTED]> To: "Struts Users Mailing List" Sent: Thursday, August 30, 2007 10:50 AM Subject: Re: Unsolved datepicker problem Su

Re: reading properties file in action class

2007-08-31 Thread Ashish Kulkarni
Hi Thanks, it works On 8/31/07, nuwan chandrasoma <[EMAIL PROTECTED]> wrote: > > Hi, > > use getResources() method in the action > > Thanks, > > Nuwan > > On 8/31/07, Ashish Kulkarni <[EMAIL PROTECTED]> wrote: > > > > Hi > > I have abc.properties and abc_fr.properties file, > > if i have to print

Re: How to access request & session objects in jsp using struts2 tags

2007-08-31 Thread Dave Newton
--- afp <[EMAIL PROTECTED]> wrote: > To access the request object in the jsp using > struts2 tags this is what we have to do For the sake of completeness this accesses request parameters, not the request object. d. - To unsub

Re: s:submit tag question

2007-08-31 Thread darnDao
:) The JSP fragment (fingers crossed): mihel wrote: > > N N wrote: >> And a JSP (fragment): >> >> ... >> >> >> >> >> >> >> ... > > It's a miracle. > Empty JSPs don't usually result in any request parameters. > > -

Re: reading properties file in action class

2007-08-31 Thread nuwan chandrasoma
Hi, use getResources() method in the action Thanks, Nuwan On 8/31/07, Ashish Kulkarni <[EMAIL PROTECTED]> wrote: > > Hi > I have abc.properties and abc_fr.properties file, > if i have to print values from properties file in jsp i use tag > and it will print value depending > on locale, > But w

reading properties file in action class

2007-08-31 Thread Ashish Kulkarni
Hi I have abc.properties and abc_fr.properties file, if i have to print values from properties file in jsp i use tag and it will print value depending on locale, But what i want to get those values in action class, is there an direct method to do so, Like some thing getText("PL1143.datecompare") i

Re: s:submit tag question

2007-08-31 Thread Oleg Mikheev
N N wrote: And a JSP (fragment): ... ... It's a miracle. Empty JSPs don't usually result in any request parameters. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]

Re: How to access request & session objects in jsp using struts2 tag

2007-08-31 Thread Chris Pratt
It's JSP 2.0 EL (which isn't specific to JSTL any longer) so you should be able to use it. Otherwise you'll have to look up the analogs in OGNL (I don't have my reference handy). (*Chris*) On 8/30/07, afp <[EMAIL PROTECTED]> wrote: > > np chris! > > Is tat using JSTL? I am not using JSTL in my

Re: Autocompleter JSON key/value pair to update other list

2007-08-31 Thread Musachy Barroso
See if this helps: http://www.mail-archive.com/user@struts.apache.org/msg61657.html musachy On 8/31/07, peter_smiley <[EMAIL PROTECTED]> wrote: > > Hi, > > Currently I'm using struts 2.0.9 and am trying to use the autocompleter with > a JSON key/value pair as the input for the autocompletion lis

Struts2 and JBoss 5.0.0 Beta2 deployment problem

2007-08-31 Thread REMIJAN, MICHAEL J [AG/1000]
Has any successfully deployed a Struts2 application to JBoss 5.0.0 Beta 2? When I try to do this I get the following stack trace from JBoss: Exception starting filter struts2 Unable to load bean: type: class:com.opensymphony.xwork2.ObjectFactory - bean - jar:file:/C:/jboss/jboss-5.0.0.Beta2/serve

Autocompleter JSON key/value pair to update other list

2007-08-31 Thread peter_smiley
Hi, Currently I'm using struts 2.0.9 and am trying to use the autocompleter with a JSON key/value pair as the input for the autocompletion list. What I would like to do is when a value is selected that the key and value are available so that I can insert them in another dropdown select, but curre

[s2] custom ExceptionMappingInterceptor log

2007-08-31 Thread johana pin
Hi, I extended 'ExceptionMappingInterceptor' to add the logging functionality. I want to log to my own file. The problem is that the logging is done in SystemOut file. I used log4j in the custom interceptor: private org.apache.commons.logging.Log log = LogFactory.getLog(getClass()); The log4j

Re: How to access request & session objects in jsp using struts2 tags

2007-08-31 Thread afp
First issue solved!! To access the request object in the jsp using struts2 tags this is what we have to do if ur url was *.action?abc=xyz then would give the value of the request parameter called abc and print xyz in this case. So learning is tat we have to use #parameters[''] instead of #req

s:submit tag question

2007-08-31 Thread N N
Hi, I've got the following code: package foo.actions; import com.opensymphony.xwork2.ActionSupport; import java.io.*; public class Bar extends ActionSupport { private String number1; private String number2; private String number3; public String execute() throws Exception

RE: Can you specify the name of struts.xml for Struts2?

2007-08-31 Thread Lane, Ron
Zarar, This probably won't do the trick, since the classpath is for the entire Java Application server, and struts.properties is then for the entire Java App server. Then the new name of struts.xml would apply to all the web apps in the Java app server. We need a parm that is in web.xml, so it is

map file extension to velocity

2007-08-31 Thread Leonidas Papadakis
Hi there, can anyone tell me how can i map .shtml extension to be parsed as velocity file, like .vm ? Thanks - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]

Re: struts2 velocity file extension

2007-08-31 Thread Leonidas Papadakis
any ideas anyone please ? Leonidas Papadakis wrote: Mistype on the subject , i mean struts2 Leonidas Leonidas Papadakis wrote: Greetings to all, can anyone suggest to me please how do i change the velocity file extension from .vm to .shtml ? Thank very much Leonidas

Re: [S2] Integrating with springframework and tiles

2007-08-31 Thread Antonio Petrelli
2007/8/31, Eugen Stoianovici <[EMAIL PROTECTED]>: > > I'm using using struts 2.0.9 with springframework 2.0.6 and i want to > use tiles as a template engine. Now in struts1 i would use > org.apache.struts.tiles.xmlDefinition.I18nFactorySet to initialize the > org.springframework.web.servlet.view.t

Re: How to give a text field name dynamically?

2007-08-31 Thread Nuwan Chandrasoma
Hi, try something like this and see Question value="route" /> Thanks, Nuwan Subhani Shaik wrote:u Hi, I have the following code... Question value="route" />