Topic: Error with XAJAX_PROCESSING_EVENTS and scriptdeferal

Hello,

i have problems using XAJAX_PROCESSING_EVENTS and scriptdeferal

Tested on versions:

  • 0.5 rc1,

  • 0.5 rc3,

  • 0.5 final standard,

  • 0.5 current svn trunk

Affected version: All

Problem description:
Once the XAJAX_PROCESSING_EVENTS are loaded, debug output and the message below is going to the generated link from scriptdeferal.

  1. inactive scriptdeferal active PROCESSING_EVENTS:  xajax working as expected.

  2. active scriptdeferal inactive PROCESSING EVENTS:   xajax working as expected.

  3. active scriptdeferal active PROCESSING_EVENTS:  xajax Error The generated script tag contains:
    <?xml version="1.0" encoding="utf-8" ?><xjx><cmd cmd="dbg">Error:  You cannot mix response types while processing a single request: xajaxResponse)</cmd></xjx>

Expected behaviour: when scriptdeferal works without PROCESSING_EVENTS it should work with PROCESSING_EVENTS as well.


help is appreciated :)

Last edited by sinza (2009-12-28 7:35:19 PM)

Re: Error with XAJAX_PROCESSING_EVENTS and scriptdeferal

found NOT the solution.

-> http://community.xajaxproject.org/topic … avascript/
-> http://community.xajaxproject.org/viewt … 628#p26628

I found the problem, but i doesn`t find a solution.

When i load my XAJAX_PROCESS_REQUEST class, and register the XAJAX_PROCESS_EVENT methods, the method get a trigger and fires the $objResponse inside.
This crashes when scriptdeferal is active.
I tried to load the Process Events after the after the xajax->processRequest(). When doing this, the Methods are registered but they don`t work.

The solution would be to check if we are in the register event or in a running state. Unfortunalety i can not find a trigger to catch what event we are in.
As i found out, its also not possible to give parameters to register events wich could be a solution.

Any idea`s ?

Last edited by sinza (2010-01-09 12:09:59 AM)