You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@struts.apache.org by Dave Bender <db...@umn.edu> on 2005/09/30 01:00:42 UTC
Struts hangs on
I'm having a problem where Struts has begun 'hanging on' to Web browser
requests. I'll call up an Action and the page comes back pretty instantly,
as you'd expect, but the little 'still-downloading' image keeps whirling for
about 30 seconds. I've tried to track this down thorough my debugger but
the request flies through to the end of the Action.execute() method, where I
return a forward. Sometime after that it hangs for about 30 seconds, then
the request completes. This happens for all Actions in the project. I'm
using Tiles, if that makes a difference.
Does this symptom sound familiar to anyone? Any suggestions would be
appreciated.
Dave Bender
Re: submit buttons - how to put them label from resource
Posted by Laurie Harper <la...@holoweb.net>.
Wendy Smoak wrote:
> From: "Borislav Sabev" <b....@eventsoft.de>
>> I'd like to set a label of submit buttons getting it from property
>> file. But seems that this is not possible.
>> One other problem I see is that value attribute has two purposes: to
>> set the label, and on submit to provide value for the request
>> parameter. Is there any way they to be different?
>
> No. I get around it with client-side scripting. (It's an intranet app,
> so I can guarantee JavaScript is enabled.)
>
> <html-el:submit property="submit" onclick="setUserAction('Add
> Prospect');" styleClass="addButton" titleKey="button.add.prospect"
> value="Add"/>
>
> function setUserAction(target) {document.forms[0].userAction.value=target;}
Another approach, which avoids the need for client-side scripting, is to
use a different request parameter for each submit button and test for
the presence of the parameter, ignoring its value.
L.
---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org
Re: submit buttons - how to put them label from resource
Posted by Wendy Smoak <ja...@wendysmoak.com>.
From: "Borislav Sabev" <b....@eventsoft.de>
> I'd like to set a label of submit buttons getting it from property file.
> But seems that this is not possible.
> One other problem I see is that value attribute has two purposes: to set
> the label, and on submit to provide value for the request parameter. Is
> there any way they to be different?
No. I get around it with client-side scripting. (It's an intranet app, so
I can guarantee JavaScript is enabled.)
<html-el:submit property="submit" onclick="setUserAction('Add Prospect');"
styleClass="addButton" titleKey="button.add.prospect" value="Add"/>
function setUserAction(target) {document.forms[0].userAction.value=target;}
--
Wendy Smoak
---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org
Re: submit buttons - how to put them label from resource
Posted by Michael Jouravlev <jm...@gmail.com>.
On 9/30/05, Borislav Sabev <b....@eventsoft.de> wrote:
> One other problem I see is that value attribute has two purposes: to set
> the label, and on submit to provide value for the request parameter. Is
> there any way they to be different?
No.
> (consider i18n problem: my buton can have German, English, Italian etc
> labels but the parameter value I'd like to recieve always "save",
> "cancel" etc.
> Does somebody know something about this problem?
See LookupDispatchAction, it adds a level of indirection allow you to
use arbitrary caption. Or try my SelectAction:
See bug #30292:
http://issues.apache.org/bugzilla/show_bug.cgi?id=30292
or download from here:
http://struts.sourceforge.net/strutsdialogs.
Docs are here:
http://struts.sourceforge.net/strutsdialogs/selectaction.html
Live demo:
http://www.superinterface.com/strutsdialog/selectaction.html
Michael.
---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org
Re: submit buttons - how to put them label from resource
Posted by atta-ur rehman <at...@gmail.com>.
<html:submit property="submitButton">
<bean:message key="submit" bundle="caption"/>
</html:submit>
On 9/30/05, Borislav Sabev <b....@eventsoft.de> wrote:
>
> Hi all,
>
> I'd like to set a label of submit buttons getting it from property file.
> But seems that this is not possible.
> One other problem I see is that value attribute has two purposes: to set
> the label, and on submit to provide value for the request parameter. Is
> there any way they to be different?
> (consider i18n problem: my buton can have German, English, Italian etc
> labels but the parameter value I'd like to recieve always "save",
> "cancel" etc.
> Does somebody know something about this problem?
>
> Borislav
>
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
> For additional commands, e-mail: user-help@struts.apache.org
>
>
submit buttons - how to put them label from resource
Posted by Borislav Sabev <b....@eventsoft.de>.
Hi all,
I'd like to set a label of submit buttons getting it from property file.
But seems that this is not possible.
One other problem I see is that value attribute has two purposes: to set
the label, and on submit to provide value for the request parameter. Is
there any way they to be different?
(consider i18n problem: my buton can have German, English, Italian etc
labels but the parameter value I'd like to recieve always "save",
"cancel" etc.
Does somebody know something about this problem?
Borislav
---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org