Any advice, please ?
Thanks.
-Message d'origine-
De : Celinio Fernandes [mailto:cel...@yahoo.com]
Envoyé : dimanche 15 novembre 2009 23:08
À : Struts Users Mailing List
Objet : [Struts 2.1.8] datetimepicker and action: String or Date ??
Hi,
I have struts2-core-2.1.8.jar and xwork-core
This is what I get :
java.text.ParseException: Unparseable date: "2009-11-20T00:00:00+01:00"
java.text.DateFormat.parse(Unknown Source)
-Message d'origine-
De : Fernandes Celinio [mailto:cfernan...@sopragroup.com]
Envoyé : lundi 16 novembre 2009 10:40
À : Struts Users Mailin
2009/11/16 Fernandes Celinio :
> This is what I get :
> java.text.ParseException: Unparseable date: "2009-11-20T00:00:00+01:00"
> java.text.DateFormat.parse(Unknown Source)
Could you show the whole stack?
Regards
--
Lukasz
http://www.lenart.org.pl/
-
Paul,
Thanks for your reply.
My DispatchActions are classes of type myproject.myactions, for example.
Shouldn't I be able to add the line
log4j.logger.myproject.myactions.myaction=DEBUG
and have the level defined for this class alone?
--
View this message in context:
http://old.nabble.com/D
Well, thanks for helping.
I am going to switch to a simple textfield tag if datetimepicker is so messy
regarding date format and conversion.
Anyways here is the source code again :
In my JSP (I choose MM/. It returns a Strign with this
format : 2009-11-24T00:00:00+01:00
Loggers need to be referenced by the name passed into their constructor.
For example:
package org.something;
class A {
protected static final log = Logger.createLogger(A.class);
}
package com.something;
class B extends A { }
The name of the logger is "org.something.A" (the class reference is a
Hi all ,
I am doing server side validation using validate method inside my action
class.I need to validate the textfield whether it is a null and if not it
should be numeric.
My jsp page is as follows:-
<%...@page contentType="text/html" pageEncoding="UTF-8"%>
http://www.w3.org/TR/html4/loose.d
Fernandes:
> java.text.ParseException: Unparseable date:
> "2009-11-20T00:00:00+01:00"
> java.text.DateFormat.parse(Unknown Source)
I have seen this behavior before.
The date format you have is an ISO format, but
the Java DateFormat class does not parse dates
in that format.
I think you
Vikrant:
> Here I am able to validate for not null fields. But I also
> want to validate
> it for the field if not null should be numeric. How Can I do this??
> Please Suggest me possible solution in order to validate both things.
Have you tried making your fields int instead of String?
Whenever Tomcat starts up it appears that the validation of the Tiles2
XML document is trying to be verified against the DTDs. The 2.1 DTD is
in the tiles JAR file. I have tried to specify the path locally in the
XML DOCTYPE tag, but it continues to want to point to an invalid
location based off
Sanjaya Kumar Patel wrote:
I saw ACEGI a bit and then am thinking to first try writing own
interceptor - basically extending the suggestion in the book "Apache
Struts 2 Web 2.0 Projects." Will post the code once successful.
For security this is pretty much always a mistake. You don't want bugs
If I am declaring it as int how should I check for null. Can u explain me
please?
--
View this message in context:
http://old.nabble.com/Struts2-Multiple-validation-for-single-field-tp26373102p26373588.html
Sent from the Struts - User mailing list archive at Nabble.com.
---
2009/11/16 CRANFORD, CHRIS :
>
> Whenever Tomcat starts up it appears that the validation of the Tiles2
> XML document is trying to be verified against the DTDs. The 2.1 DTD is
> in the tiles JAR file. I have tried to specify the path locally in the
> XML DOCTYPE tag, but it continues to want to
2009/11/16 Antonio Petrelli :
> 2009/11/16 CRANFORD, CHRIS :
>>
>> Whenever Tomcat starts up it appears that the validation of the Tiles2
>> XML document is trying to be verified against the DTDs. The 2.1 DTD is
>> in the tiles JAR file. I have tried to specify the path locally in the
>> XML DOCT
Ya Now its working fine. I am running this application on jboss server. While
the application is running I am getting lot of errors in the console such as
follows:-
Any suggestions Please in order Not to get such kind of errors
20:50:58,950 WARN [OgnlValueStack] Error setting value
ognl.MethodFa
Vikrant:
> If I am declaring it as int how should I check for null.
OK, I think I see what you are asking.
If you change your field to an int field and the
user does not fill in the value, you will
get zero. If they put in zero, you will get zero
and there is no way to tell the difference.
Is
Here is the version history:
Tomcat6.0.20
Struts2.1.6
Tiles 2.1.4
Hibernate 3.3.2
Spring2.5.3
> -Original Message-
> From: Antonio Petrelli [mailto:antonio.petre...@gmail.com]
> Sent: Monday, November 16, 2009 9:15 AM
> To: Struts Users Mailing List
> Subject: Re: Tiles wi
Done, sorry.
> -Original Message-
> From: Antonio Petrelli [mailto:antonio.petre...@gmail.com]
> Sent: Monday, November 16, 2009 9:16 AM
> To: Struts Users Mailing List
> Subject: Re: Tiles with Struts2 & Tomcat
>
> 2009/11/16 Antonio Petrelli :
> > 2009/11/16 CRANFORD, CHRIS :
> >>
> >>
Hi ALL,
In my Struts2/jsp form I have three buttons. When any of these buttons are
clicked and once the action is successfull I want to dynamically show a
message on the same page where these buttons are .
Any Suggestions please in order to handle such case.And also the message
should be different
Vikrant:
> 20:50:58,950 WARN [OgnlValueStack] Error setting value
> ognl.MethodFailedException: Method "setLoad" failed for object
> com.tcs.infra.workload.remoteclientact...@161ef9c
This is no big deal since it is just a warning.
If you want to keep your field as an int, you can
implement a me
Could someone show me the correct way to insert a string field length into
the size attribute of a element.
Regards
--
View this message in context:
http://old.nabble.com/OGNL-expression-help-tp26373897p26373897.html
Sent from the Struts - User mailing list archive at Nabble.com.
--
Thanks Niel For Your Help
--
View this message in context:
http://old.nabble.com/Struts2-Multiple-validation-for-single-field-tp26373102p26373908.html
Sent from the Struts - User mailing list archive at Nabble.com.
-
To
The code examples pasted confuse me; I don't know what are you
trying to accomplish. Please pick one:
1. You have a where the user provides data. You wish to
relay that data to a Struts action class.
2. You have data supplied by the server. You wish to include
that data in a hyperlink
For this example pretend your field "firstname" has a max length of 15:
> -Original Message-
> From: RogerV [mailto:roger.var...@googlemail.com]
> Sent: Monday, November 16, 2009 10:29 AM
> To: user@struts.apache.org
> Subject: OGNL expression help
>
>
> Could someone show me the corr
Thanks, I changed action in requestUri from ajax to a normal one. Now sorting
and paging work fine although it's not ajax.
Is it possible to do the sorting and paging in an ajax way?
Oscar Calderón-2 wrote:
>
>
> Well, it depends of the display table's configuration. In display table
> tag y
> > Could someone show me the correct way to insert a string
> > field length into
> > the size attribute of a element.
>
I think he was looking for something more involved,
something like:
I have not tested code to do this, so I don't know if
that would work. Also, what if the myString
Kawczynski, David wrote:
>
> For this example pretend your field "firstname" has a max length of 15:
>
>
LOL :) I suspect that my difficulties in trying to use OGNL to insert the
length are related to the fact that the method call on a string is
String.length() not String.getLength and when
Hi Neil,
That was a good lead. Thanks.
I used this format :
SimpleDateFormat formatter = new SimpleDateFormat("-MM-dd'T'HH:mm:ss");
I checked the source of the DateTimePicker class to get the correct format.
So I got it working now but that was a pain.
-Message d'origine-
De
> That was a good lead. Thanks.
> SimpleDateFormat("-MM-dd'T'HH:mm:ss");
> So I got it working now but that was a pain.
I am glad you found the suggestion useful and were
able to get it working.
I see you skipped the time zone in your format.
That is another pain, the DateFormat class
doe
> length are related to the fact that the method call on a string is
> String.length() not String.getLength and when I use
> size="%{attrib.length}"
> OGNL is trying to call getAttrib().getLength() on my action
You could create your own MyString class that
extends String and then have a getLengt
I skipped it because I cannot figure out the format to handle that colon in the
middle of that time zone.
I tried without that time zone and saw that it works anyways.
Thanks again.
-Message d'origine-
De : Neil Aggarwal [mailto:n...@jammconsulting.com]
Envoyé : lundi 16 novembre 2009
Like Neil suggested, use "attrib.length()" The extra parens cause OGNL to
call getAttrib().length() rather than getAttrib().getLength().
(*Chris*)
On Mon, Nov 16, 2009 at 8:08 AM, RogerV wrote:
>
>
>
> Kawczynski, David wrote:
> >
> > For this example pretend your field "firstname" has a max
2009/11/16 Neil Aggarwal :
> You could create your own MyString class that
> extends String and then have a getLength() method
> that calls super.length().
Extending String? String is final so it isn't doable ;-)
Regards
--
Lukasz
http://www.lenart.org.pl/
-
> I skipped it because I cannot figure out the format to handle
> that colon in the middle of that time zone.
The only solution I found was to manually take it out of the
date string.
Neil
--
Neil Aggarwal, (281)846-8957, http://UnmeteredVPS.net
Host your struts app on a CentOS VPS f
> Extending String? String is final so it isn't doable ;-)
I did not check that.
I see someone posted a better solution than this but
I guess if someone wanted to have a getLength() for
a String, they could write a container class that
holds a String and then implement all the methods to
call
The Apache Struts Team is pleased to announce that Struts 2.1.8.1 is
available as a "General Availability" release. The GA designation is
our highest quality grade.
[http://struts.apache.org/download.cgi#struts2181]
The release is also available from the central Maven repository under
Group ID "o
Hi to all. I'm developing a Struts 2 application and i create an
interceptor to initialize values and to validate user login. I want to
load a list to jsp to populate a s:select so i implemented the
Preparable interface in my action, and the method prepare(), so i type
the code in this method t
Put each button in it's own form, and assign a hidden variable in each form
with a different value for each button/form. In your action class, check the
value of the parameter, set a generic message string based on the parameter
value, then redisplay the page with the forms on it.
--
View this m
Did you either set your appInterceptors stack to be the default stack, or
define the actions you're testing with to use the appInterceptors stack
explicitly? Otherwise, you're actually just using the defaultStack.
(*Chris*)
On Mon, Nov 16, 2009 at 12:34 PM, Oscar wrote:
> Hi to all. I'm devel
Chris Pratt escribió:
Did you either set your appInterceptors stack to be the default stack, or
define the actions you're testing with to use the appInterceptors stack
explicitly? Otherwise, you're actually just using the defaultStack.
(*Chris*)
On Mon, Nov 16, 2009 at 12:34 PM, Oscar wrote:
Hi,
I am writing an interceptor that will re-populate the spring security context.
For example, this will allow me to annotate my ChangePasswordAction with
@Refresh, so after invocation, the SecurityContext will also contain the
changed password. To do this, my interceptor needs a copy of th
HI Fernando,
For what it¹s worth in applications where we have a diverse range of locales
we found that it was best to create our own date converter.
The date converter then reads our properties file which contains an entry
with a comma delimited list of date formats which the date converters tri
I already have defined three different actions for each button. The thing
which I want is that when I click any of this button and the action class
returns a success then there should be a dynamic message on the same page
where the buttons are , that the action has been successfull. How can I do
43 matches
Mail list logo