is the user "cancelling" still sending a request to the server and hence you
are trying to return an error - if so i'd assume the http connection has been
terminated and therefore you can't send an http response back.
if its just logged but doesn't stop user experience then leave it.
> To: us
if you don't use AJAX then you can only do the standard get/post based on form
submission which is a synchronous call.
you can use AJAX functionality straight from plain old javascript without using
DOJO or other javascript libraries - its just those libs make it easier.
adam
> Date:
i dont use the osiv filter i just make sure the DAO object method returns the
objects initialised correctly (i.e. all lazy collections that are to be
accessed are initialised) for how its going to be used - i might have a DAO
method to return the plain object with no collections initialised an
inside a pdf able to print???
> ok can u please send that java script file to
> me.(nagarjunabatt...@gmail.com)
>
> adam pinder wrote:
> >
> >
> >
> > i think all interactions using window.print require the user to at least
> > acknowledge that they wan
teraction after pressing ok.
> can u help me regarding this
>
>
> adam pinder wrote:
> >
> >
> >
> > window.open is not a synchronous command and hence the window.print is
> > occurring before the jasper report is actually rendered and you need to
> &
i'm not sure what tests can be done on the variable created from the
window.open - if you can test for it being loaded and are able to issue a print
against the actual new window then that would be simplest otherwise...if the
call to the jasper report could output an html page containing the r
window.open is not a synchronous command and hence the window.print is
occurring before the jasper report is actually rendered and you need to issue
the window.print on the new window which i doubt it is given you're calling it
from the parent window.
you need to be able to test that the new w
i would start with the struts2 sample app, get it working then add hibernate3
(this adds a lot of new jars) get struts2 and hibernate3 working then add
tiles2 and get that working - don't try and throw them all in together then try
to work out which one is causing the issue.
> Date: Thu, 10 F
make sure you only add additional jars into the web app itself and avoid
(mostly) adding jars into common library folders.
i use struts2 and hibernate3 but not tiles and have no problems like yours.
adam
> Date: Thu, 10 Feb 2011 14:53:52 +0530
> Subject: Decent tutorial or working example of Hi
Anjib,
i'd certainly take a look at hibernate, i've been using it for a while now and
find it easy enough and functionally rich enough for most things.
adam
> Date: Tue, 7 Dec 2010 14:36:01 -0500
> From: anji...@hotmail.com
> To: user@struts.apache.org
> Subject: Connection Pooling with
maybe your xml does not match the struts2 DTD (defined at top of struts.xml) -
try checking xml in something like XMLSpy for invalid xml as error says.
> Date: Wed, 20 Oct 2010 10:34:01 +0900
> Subject: Re: Can't deploy on server
> From: liying.cn.2...@gmail.com
> To: user@struts.apache.or
Hi Li / Maurizio,
thanks for your replies - i did receive the answer from another user yesterday
too, he sent the following
Actually, I found the solution, and it works for me:
http://old.nabble.com/-S2--2.2.1-possible-freemarker-template-bug-td29462347.html
Just add this to your web.xm
you show us your setting file(struts.xml and so on) and your jsp code?
>
>
> 2010/10/19 adam pinder :
> >
> >
> >
> > I have just upgraded struts2 version from 2.0.11 to 2.2.1 and one issue
> > seems to be that i have amended templates
> >
> > actioner
I have just upgraded struts2 version from 2.0.11 to 2.2.1 and one issue seems
to be that i have amended templates
actionerror.ftl
actionmessage.ftl
and they were placed into WebContent\template\simple folder in the web app and
with 2.0.11 they overrided the templates in the struts2 core j
i've only used jfreechart with struts2 (not portlets) and its more to do with
the way the result is returned than the action class itself.
in struts.xml i have
and then referenced in action definition
400
400
then in action the field chart will have m
if you're new to struts why don't you use struts2 its far better and less
intrusive code wise.
> Date: Tue, 28 Sep 2010 09:03:51 +0530
> Subject: Re: Accessing User input in execute ( ) method
> From: hareend...@gmail.com
> To: user@struts.apache.org
>
> Guys,
>
> Thnks for all replie
one action per function or functional area is probably best.
you can then tailor the validation and responses more easily.
adam
> Date: Fri, 24 Sep 2010 10:35:42 +0100
> Subject: How to structure a struts2 application
> From: darrenkarst...@gmail.com
> To: user@struts.apache.org
>
adam
> Date: Sun, 12 Sep 2010 18:04:38 -0400
> Subject: Re: Array Input Fields
> From: davelnew...@gmail.com
> To: user@struts.apache.org
>
> Look at the type conversion docs: there's a difference between using
> [] and () in the JSP names.
>
> On Sunday, S
> On Saturday, September 11, 2010, Chris Mawata
> wrote:
> > On 9/10/2010 1:08 PM, adam pinder wrote:
> >
> > public User getUser(int occ)
> >
> >
> > Should the getter not return the collection rather than a single User?
> > Chris
> >
>
Using Struts 2.0.11
I have a jsp that creates elements like
etc
when the form is submitted to the server i want the parameters interceptor to
set the values on each user object so i have a method
public User getUser(int occ)
{
return users.get(occ);
}
which
your action could implement ServletRequestAware then it has access to the full
request including posted content.
adam
> From: arunkumar.bopp...@gmail.com
> Date: Fri, 30 Jul 2010 15:31:15 +0530
> Subject: Re: Reading input stream (xml)
> To: user@struts.apache.org
>
> Request to this
if your security is simple - fixed roles to access certain actions...
i created a custom role interceptor added it to the interceptor stack and then
just added struts.xml definitions with
member
the allowedRoles value can be comma separated to allow multiple r
can't you specify a filename in the result config in the struts.xml file,
albeit it the same for each result.
> Date: Wed, 14 Apr 2010 09:57:54 +0800
> From: haoniu...@gmail.com
> To: user@struts.apache.org
> Subject: Re: struts & PDF
>
> You can't. On
put them before action definitions.
adam
> Date: Tue, 6 Apr 2010 00:47:22 -0700
> From: rakeshknai...@gmail.com
> To: user@struts.apache.org
> Subject: struts 2 global result problem
>
>
> hi
>
> I am using struts2.1.6 in my application.i want to use
so it looks like your issue is more to do with the child values not being set
by Struts
there have been a few postings about using the [] notation on field names to
get struts to assign the values properly.
in struts1 i found it worked fine, however in struts2 i've not really seen it
work
seems like form definition isn't in struts config file or properly defined
> Date: Thu, 1 Apr 2010 11:45:42 +
> To: user@struts.apache.org
> Subject: Error creating form bean struts 1.2 + weblogic 8.1 + myeclipse 5.5
> From: nanukh...@rediffmail.
set the rootlogger to warn
log4j.rootLogger=warn, stdout
rather than debug
you should only get a parameterinterceptor log entry every time you post
something to the server
> From: brgrandj...@live.fr
> To: user@struts.apache.org
> Subject: RE: CRUD
in log4j.properties file (same location as struts.xml and hibernate config
files)
add
log4j.logger.com.opensymphony.xwork2.interceptor.ParametersInterceptor=debug
this will output param name/value pairs being posted from your page.
> From: br
turn on the parameterinterceptor logging and make sure as mentioned that
1) the values you expect for each child are being sent to the server (id and
name)
2) the parameter names are correct for setting each child
i had some issues getting lists of items to be updated by form submission
have you got the correct cascade setting on the parent object
i use the xml files for hibernate rather than the @ syntax in java classes and
i can set cascade="all" which means when i save/update the parent the children
are also saved or updated.
also remember that for hibernate to realise
try & instead of &
> Date: Wed, 31 Mar 2010 08:41:39 -0700
> From: pankajj.j...@gmail.com
> To: user@struts.apache.org
> Subject: Regular expressions - Email Validation
>
>
> In struts I have regular expression for validating email like this -
>
>
i prefer pagination to be db based so there is a minimum amount of data
retrieved and held in memory. i.e. only retrieve what you will display. don't
retrieve 200 records in memory and page through them.
adam
> Date: Mon, 29 Mar 2010 03:07:25 -0700
r
> them , how do I get the select state restored ? As of now , they take the
> default value even after making a different selection.
>
> regards,
> Pundarik
>
> On Wed, Mar 24, 2010 at 11:29 PM, adam pinder wrote:
>
>>
>>
>> as long as you are simply re-displ
as long as you are simply re-displaying the same form associated with the same
action it should work like any other page - the input fields are struts2 tags
and there are getters for each property in the action it should retrieve the
value and re-display them
i have a similar thing and it w
the only thing i have different is a space before and after the = in the
resource file
apart from that i'm using getText as you are.
adam
> Date: Tue, 23 Mar 2010 11:12:19 -0700
> Subject: Weird behavior in getText()
> From: thechrispr...@gmail.com
hibernate can use parameterised statements out of the box and handles the
encoding of values to stop sql injection.
you can use names like
:orgId
in an sql statement and set either the value with a set statement or by setting
an object containing a getOrgId method and hibernate will c
use hibernate its definitely worth trying.
the SQL queries can be parameterised and the parameter names can refer to
fields in an object, it handles the escaping of values to be sql safe.
> From: gustavo.felisbe...@wit-software.com
> To: user@stru
you want to save the options in the select not a selected option...
if you make the select a multiple select and in javascript you select all
options are all the option values sent to the server against the same
parameter name (turn on parameter interceptor logging to check)...
if so,
Store the data entered in an object and have it in the session, making the
get/set for the object do a get/put into the session.
they can change to their hearts content.
> Date: Wed, 17 Mar 2010 02:52:50 +0530
> Subject: Can we some how persist for
> yes, of course...
> >
> > but imagine you have a list of elements, how do you pass the Id of the
> > element you want to display in other page with a s:submit???
> > (I cant use javascript)
> > 2010/3/6 Adam Pinder
> >
> >> Any form textfield will
Any form textfield will be submitted when page submitted which is
effectively a parameter.
Adam
On 5 Mar 2010, at 19:46, lucas owen wrote:
Hi Struts users:
I'm wondering if it is possible to pass a parameter inside a
s:submit tag.
I'm working with the following form (this is just a ske
You don't redirect on validation errors.
A jsp page form is associated with an action, the same jsp is
displayed on validation errors then the action and jsp will re-
display the erroneous values automatically. Redirect on success is
more common.
Adam
On 5 Mar 2010, at 21:37, Siddiq Syed
are you sure its not your appserver logging and not struts logging.
adam
> Date: Fri, 5 Mar 2010 11:02:07 +0100
> From: carl.ballant...@cast-info.es
> To: user@struts.apache.org
> Subject: RE: Struts 2, Log4J and turning off WARNING messages
>
> Thanks Raghuveer,
>
> I already have th
; abhi
>
> On Fri, Mar 5, 2010 at 2:10 PM, adam pinder wrote:
>
> >
> >
> >
> > is it a file on the client side or server side ?
> >
> >
> >
> > if client side, you can specify a result type in the struts.xml but the
> > us
on my end, I am sure there must be a method to
> redirect the output of *out *to a file and not to STDOUT or so.
>
> thanks
> abhi
>
> On Fri, Mar 5, 2010 at 2:10 PM, adam pinder wrote:
>
> >
> >
> >
> > is it a file on the client side or server side
is it a file on the client side or server side ?
if client side, you can specify a result type in the struts.xml but the user
will be prompted to save the file as its a security risk to write it without
there confirmation.
server side, just use plain java code in jsp to write and then
just pass an alias to the locale in the parameter
and let the getName class handle the actual locale.
adam
> Date: Thu, 4 Mar 2010 18:20:19 +0100
> Subject: Re: Passing parameters to
> From: lukasz.len...@googlemail.com
> To: user@struts.apache.org
>
> 2010/3/4 Ricardo Jorge :
use an alias in the getName call like so
this will still call getName but pass the string "US" then make the class
method getName do the locale related work.
you can't pass an object in a property call as far as i know only a
primitive/string.
i still think you should be look
box.
> Even one select box also not working.
> Now I have to use this jquery select box to complete this task fast.
> or else i need to write so much code to do this task.
>
> Thanks
> RS
>
>
> adam pinder wrote:
> >
> >
> >
> > why did you c
why did you choose to use jquery rather than just normal struts select and let
the action class create an array of objects (i use an object that has a
key/value pair)
i haven't used jquery but not sure what extra it adds.
adam
> Date: Thu, 4 Mar 2
i think you can name the resource bundle files appropriately for the locale and
put them in the same package as the action classes.
look at the I18n Interceptor
adam
> Date: Thu, 4 Mar 2010 11:19:53 +0530
> Subject: Locale and custom variables
> From
use a smaller font for the dropdown content or abbreviate the text or can the
option value be the long text and the displayed value be much shorter ?
> Subject: RE: horizontal scroll in
> Date: Wed, 3 Mar 2010 09:22:46 -0500
> From: david_kawczyn...
I personally use the standard tag not the struts one and use struts to
populate the tooltip with so some
link text
not sure the struts really adds much as the href is likely to be just the
action name not the full URL anyway.
adam
> Date: Wed,
in case anyone else encounters similar issue.
i forced the locale to en_GB (using datetimepicker with dd/mm/ format) by
adding it into struts.xml and now it works.
what was happening was that the dates on the url were not being converted into
java.util.Date fields because they were de
Alex,
just checked my code again and it required me to handle the parameters myself -
i added some code into the prepare method and checked request parameters and
updated the arraylist myself (it was a while ago i had this problem).
In struts1 it would have worked, i couldn't get it to wor
Alex,
i used the following and it worked ok with struts2.
In JSP :-
In Action, i have a get/set for opportunity which is an object with the
following property (with get/setters)
private Collection opportunityItems = new ArrayList(0);
and the following additional method in the op
BACKGROUND:
I have the following line in a jsp page that is shown after login
findMyActivityYes
This action simply gathers data and stores it in a session object.
Later on in the same jsp page i then have lines like
The GenerateChart action uses the session object (from TeamActivity
57 matches
Mail list logo