views:

10

answers:

0

Hi , i want to upload a file and update result in other div on the same page dynamically just by showing a string "succeed/failed". It is working fine when i am forwarding result to a new page. However for below mentioned code it is updating div id "two" to [object HTMLDocument]. Please show me the way to solve it.

<div id='two' style="border: 1px solid yellow;"><b>initial content</b></div>
<s:form id='theForm2' cssStyle="border: 1px solid green;" enctype="multipart/form-data" action='doUpload' method='post' theme="ajax">
<input type="file" name="upload" />
<s:submit value="GO2" theme="ajax" targets="two"/>
</s:form>