Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Return no view from action in ajax requests struts 2

Tags:

ajax

struts2

I have a drop down list for locale selection, when user changes it then i send an ajax request to an action where i set a session perimeter

Now the problem is that what should i return from the execute() method of the action

like image 670
Sumit Jain Avatar asked Dec 21 '22 16:12

Sumit Jain


1 Answers

You can return an HTTP 200 OK, which should be an empty, successful response.

<result name="empty" type="httpheader">
    <param name="status">200</param>
</result>

I would make a global result so that you can use it any action.

like image 120
Steven Benitez Avatar answered Jan 09 '23 09:01

Steven Benitez