• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Struts2 redirect in div

 
Greenhorn
Posts: 1
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
hi!
i'm trying to load content of a div with a page loaded from success forward of an action in struts2;

But it's not working... it replaces THE WHOLE PAGE.
i want to see my form again, under my new jsp

is it possible?? what am i doing wrong?

thanks
Andrea


StartingPage.jsp
<div id='two' style="border: 1px solid yellow;">Initial content</div>
XXX
<s:form
id='theForm2'
cssStyle="border: 1px solid green;"
action='MyAction!step2'
method='post'
theme="ajax">

<input type='text' name='data' value='Struts User' />
<s:submit value="GO" theme="ajax" targets="two" />

</s:form >

MyAction.step2
public String step2() throws Exception {
return SUCCESS;
}

struts.xml
<action name="NuovaCassettaAction" class="mypackage.MyAction">
<result name="success">/pages/newPage.jsp</result>
</action>
 
reply
    Bookmark Topic Watch Topic
  • New Topic