I usually respond with a JSON object that at least provides some debug
info like:

{msg:'panel_X removed from col1'}
{msg:'panel_X inserted in col2, position Y'}

or

{msg:'panel_X moved to position Y'}


On the client I pass the debug string to a logging function that I use
to output all my debugging stuff to any javascript console available:

con=function(action,output){try{if(typeof(window.console)!='undefined')
{ window.console[action](output); return true; }else{ return false; }}
catch(e){}}

(Example)
onSuccess:function(data){
  if(typeof(data.responseJSON)!='undefined' && data.responseJSON!=null)
{
    o = data.responseJSON;

    if( typeof(o.msg)=='string' ){
      con('info','Server: ' + o.msg); //Output the debug message
      con('dir',o);                   //Dump the rest of the servers
response
    }
  }
}
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Prototype & script.aculo.us" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to 
[email protected]
For more options, visit this group at 
http://groups.google.com/group/prototype-scriptaculous?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to