struts-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Emi Lu <em...@encs.concordia.ca>
Subject Re: <sx:head> cause <s:submit> does not work
Date Fri, 14 May 2010 18:07:02 GMT
Figure it out finally!


<sx:datetimepicker displayFormat="yyyy-MM-dd" name="date_example" /> 
(YYYY-MM-DD)

date_example has to be String but cannot be type Date.
Otherwise, <s:submit action="methodProcessAction"> Will not dispatch to 
method()!

--
Lu Ying





On 05/14/2010 11:27 AM, Emi Lu wrote:
> Good morning,
>
> This struts-dojo-tags causes s:submit does work anymore.
>
> Whenever <sx:head /> is added, none s:submit works, could someone helps?
>
> How comes?
>
>
>
>
> <s:form action="ProcessAction">
> <s:submit>
> </s:form>
>
>
> public String execute() throws Exception
> { ...
> return "update";
> }
>
> When click "submit" the execute() never being called!
>
>
> Thanks alot!
> --
> Lu Ying
>
>
>
> On 05/14/2010 09:21 AM, Emi Lu wrote:
>> Good morning,
>>
>> Struts2.1.8.1, when using <sx:head />,
>>
>> <s:submit action="method1ProcessActoin">, method1 is never triggered?
>>
>> But if <sx:head /> is removed, method1 in ProcessAction.java is called
>> successfully.
>>
>> Does someone know why?
>>
>>
>>
>> (1) struts.xml
>> <action name="*ProcessAction" method="{1}" class="ProcessAction">
>> <result name="update" type="tiles">update_menu</result>
>> <result name="error" type="tiles">update_menu</result>
>> <result name="save_success" type="tiles">main_menu</result>
>> </action>
>> (2) ProcessAction.java
>> public String execute() throws Exception
>> { ...
>> return "update";
>> }
>>
>> /* This update method is never called by <s:submit> */
>> public String update() throws Exception
>> {
>>
>> return "save_success";
>> }
>>
>> public String cancel() throws Exception
>> {
>>
>> return "save_success";
>> }
>>
>> (3) .jsp
>>
>> <s:submit value="Update" action="updateProcessAction"> </s:submit>
>> <s:submit value="Cancel" action="cancelProcessAction"> </s:submit>
>>
>>
>>
>> ProcessAction.update() is never called when <sx:head> is added into jsp;
>>
>> If <sx:head> is removed, ProcessAction.update() is called.
>>
>> Does anyone knows why?
>>
>> Thanks a lot!
>> --
>> Lu Ying
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
>> For additional commands, e-mail: user-help@struts.apache.org
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
> For additional commands, e-mail: user-help@struts.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org


Mime
View raw message