[Mono-list] JQuery

jupiter.hce at gmail.com jupiter.hce at gmail.com
Sun Aug 28 07:40:04 EDT 2011


It was a simple test running javascript on client web browser to a web server 
running on Apache & mono (with xsp and mon-mono) on CentOS 5.

The javascript called:

$.ajax({
  url: myUrl,
  data: dataString,
  dataType: "json",
  success: goodCallBack,
  error: errorCallback
});

If the dataString contained "&" for example dataString = "broken&data" or 
if the dataString contained an empty string dataString = "", the web
server would treat the dataString as a undefined object and the errorCallback 
would be called.

The same dataString would be OK if it sends to a Windows web server
running on ASP .Net.

If the dataString contained a space character, the Linux web server
replaced the space character by "+" but the Windows web server still
took it as a space character. 

If the dataString contained "=' character, the Linux web server would cut 
the string "=" and any characters after the "=", the windows server was
fine.

Also, if I open several client browsers to send dataString every
second to the same web server, the Linux web server would stop the
process after 20 minutes, but there was no problem on Windows server.

Thanks.

Jupiter

On 2011-08-27 15:34+0200, Simon Lindgren wrote:
>You need to describe your problem better.
>
>What are you trying to achieve, which web development framework are you
>using, which server software(s) is part of the request handling etc.
>
>Small (but reasonably complete) code snippets also helps the
>understanding of your problem.
>
>tor 2011-08-25 klockan 22:11 +1000 skrev jupiter.hce at gmail.com:
>> Hi,
>> 
>> I am running mono 2.10.2 version on Linux web server, it seems that the Jquery 
>> is broken when I transferred a string contained on "&" or "=" or
>> space from client javascript Jquery via ajax.
>> 
>> On server side, the "=" was replaced by "+", the "=" and all
>> characters after the "=" were cut off (like base64 padding), and the
>> server returned undefined object for "&".
>
>What do you mean by "the server returned undefined object for "&""?
>
>> 
>> I set the dataType to "json". According to the Jquery API, the ajax
>> automatically formats non-string object to JSON format and serialises the data 
>> via ajax.
>> 
>
>Look at the data transferred by using the "net" tab of firebug or
>similar tool. Is that data correct?
>
>> I guess the mono integrates the JQuery package to the mono package,
>> which version of the Jquery is in mono 2.10.2?
>> 
>
>AFAIK, mono does not come with any jQuery version at all.
>
>> I don't think it would be a bug on mono Jquery as the implementation
>> was quite common. I suspect I did not set up the Jquery properly, please
>> advise what I could be missing.
>
>In my experience, there is not much to set up when using jQuery.
>
>
>
>-- 
>Simon Lindgren
>
>_______________________________________________
>Mono-list maillist  -  Mono-list at lists.ximian.com
>http://lists.ximian.com/mailman/listinfo/mono-list

-- 



More information about the Mono-list mailing list