[haXe] Client-server remoting using headers

Michael Pliskin mike at comapping.com
Fri Dec 7 22:37:01 CET 2007


Hello list,

  I've found a pretty strange problem with haxe remoting recently, and
  I'd like to discuss a workaround. In our app, I need to send smth
  like 'logout' message when user closes browser/navigates away from
  the page. I am setting up an onunload handler in JS to send the
  message at the right time. The problem is (as my recent findings
  show) that for some weird reason in some cases only headers from
  this request reach server, not the request body itself. This leads
  to haxe remoting not working - while headers arriving successfully!

  So the workaround I propose is to introduce a 'header mode' into
  haxe remoting - when data is sent not via __x parameter in request
  body, but via some header (say X-Haxe-Remoting-Data). Of course this
  will only work for short messages I think - but this is more than
  enough for me.

  Nicolas & all, thoughts? If you like, I can make a patch..

-- 
Best regards,
 Michael                          mailto:mike at comapping.com




More information about the Haxe mailing list