Has really nobody a suggestion how to use Ajax with an aggregator? Cant
imagine, that nobody else had that problem before ;-)

kind regards,

Niclas


ZongoZongo wrote:
> 
> I found the problem, but dont know how to solve it. The problem is the
> location of the ajax-logic inside the aggregator. If its located inside a
> pipeline everything works fine. Sadly I have to put the formprocessing
> after the aggregation, because the tabs inside the form need, the tag
> <head/>, that is created after the aggregation through finalize.xsl.
> 
> Maybe somebody has an idea for a workaround ;-)
> 
> kind regards,
> 
> Niclas
> 
> 
> ZongoZongo wrote:
>> 
>> Hi
>> 
>> I updateted my form with ajax. Now Iam getting a server error like
>> described in the title of this thread when I hit the submitbutton.
>> 
>> Javastack:
>> java.lang.IllegalStateException: getWriter() has already been called for
>> this response
>> 
>> org.apache.catalina.connector.Response.getOutputStream(Response.java:568)
>> 
>> org.apache.catalina.connector.ResponseFacade.getOutputStream(ResponseFacade.java:180)
>> 
>> org.apache.cocoon.servlet.CocoonServlet.manageException(CocoonServlet.java:1316)
>>      org.apache.cocoon.servlet.CocoonServlet.service(CocoonServlet.java:1202)
>>      javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
>> 
>> Sitemap:
>>      <map:resources>         
>>              <map:resource name="page.html">
>>                      <map:aggregate element="site">
>>                              <map:part element="navigation" 
>> src="cocoon:/navigation"
>> strip-root="true"/>
>>                              <map:part src="cocoon:/{page}.source" 
>> element="main"/>
>>                              <map:part element="header" src="header.xml" 
>> strip-root="true"/>
>>                      </map:aggregate>
>>                      <map:transform type="xslt" 
>> src="stylesheets/finalize.xsl"/>
>>                      <map:transform type="browser-update"/>
>>                      <map:transform src="forms-samples-styling.xsl"/>
>>                      <map:select type="ajax-request">
>>                              <map:when test="true">
>>                                      <map:serialize type="xml"/>
>>                              </map:when>
>>                              <map:otherwise>
>>                                      <map:serialize type="html"/>
>>                              </map:otherwise>        
>>                      </map:select>
>>                      <map:serialize type="html"/>
>>              </map:resource>
>>      </map:resources>
>> 
>> template:
>> 
>> <div>
>>   <jx:import xmlns:jx="http://apache.org/cocoon/templates/jx/1.0";
>> uri="resource://org/apache/cocoon/forms/generation/jx-macros.xml" />
>>   <ft:form-template
>> xmlns:ft="http://apache.org/cocoon/forms/1.0#template"; method="POST"
>> enctype="multipart/form-data" action="#{$continuation/id}.continue"
>> ajax="true">
>>     <fi:group xmlns:fi="http://apache.org/cocoon/forms/1.0#instance";>
>>       <fi:styling type="choice" />
>>       <fi:items>
>>         <fi:group>
>>           <fi:label>abstract</fi:label>
>>           <ft:repeater id="abstract">
>>             <table>
>>               <ft:repeater-rows>
>>                 <tr>
>>                   <td>
>>                     <ft:widget id="fault-abstract" />
>>                   </td>
>>                   <td>
>>                     <ft:widget id="deleteRow-abstract" />
>>                   </td>
>>                   <td>
>>                     <ft:widget id="selectRow-abstract" />
>>                   </td>
>>                 </tr>
>>               </ft:repeater-rows>
>>             </table>
>>           </ft:repeater>
>>           <br />
>>           <ft:widget id="addRow-abstract" />
>>           <ft:widget id="deleteRows-abstract" />
>>         </fi:group>
>>         <fi:group>
>>           <fi:label>paper</fi:label>
>>           <ft:repeater id="paper">
>>             <table>
>>               <ft:repeater-rows>
>>                 <tr>
>>                   <td>
>>                     <ft:widget id="fault-paper" />
>>                   </td>
>>                   <td>
>>                     <ft:widget id="deleteRow-paper" />
>>                   </td>
>>                   <td>
>>                     <ft:widget id="selectRow-paper" />
>>                   </td>
>>                 </tr>
>>               </ft:repeater-rows>
>>             </table>
>>           </ft:repeater>
>>           <br />
>>           <ft:widget id="addRow-paper" />
>>           <ft:widget id="deleteRows-paper" />
>>         </fi:group>
>>       </fi:items>
>>     </fi:group>
>>     <ft:widget id="submitbutton" />
>>   </ft:form-template>
>> </div>
>> 
>> Maybe somebody has an Idea how to solve this problem.
>> 
>> kind regards,
>> 
>> Niclas
>> 
> 
> 

-- 
View this message in context: 
http://www.nabble.com/Ajax---on-Submit%3A-%22Requerst-failed---status%3D500%22-tf2966619.html#a8518382
Sent from the Cocoon - Users mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to