Re: jQuery again

2008-10-06 Thread Henrik Sarvell
Alex realized that the problem is a missing newline at the end of the post string today. I've covered the solution over here: http://www.prodevtips.com/2008/10/06/jquery-and-pico-lisp/ Maybe not the most elegant one, but orders of magnitude better than actually changing the jQuery core. /Henrik

Re: jQuery again

2008-10-05 Thread Henrik Sarvell
I don't know what I might have done the last time when I got that result after 7 minutes, it did not happen this time, I'm using a different version of Firefox and Firebug this time though. Anyway this time I traced line also, here is the result I get immediately after making the jQuery post:

Re: jQuery again

2008-10-05 Thread Henrik Sarvell
I just downloaded the newest version from http://jquery.com and tried it as is, no zipping or packing, same result, here is the $.post function: post: function( url, data, callback, type ) { if ( jQuery.isFunction( data ) ) { callback = data; data = {};

Re: jQuery again

2008-10-05 Thread Henrik Sarvell
I want to explain why this is important for me and should be important for all. Obviously the Pico server can play nicely with Ajax calls, the form.js is an example of this, however it's heavily bound to the GUI framework, there might be many different reasons however to communicate with the

Re: jQuery again

2008-10-05 Thread Alexander Burger
Hi Henrik, The above works flawlessly with Apache + PHP. Surely jQuery will do that right, but still I do not understand where the problem might lie in the PicoLisp server. The tracing definitely shows that the HTTP header arrives, but the following POST data (a single line) don't. The

Re: jQuery again

2008-10-05 Thread Alexander Burger
On Sun, Oct 05, 2008 at 02:41:33PM +0700, Henrik Sarvell wrote: http : 5 line : line = (P O S T / @ a j a x T e s t H T T P / 1 . 1) _htHead : ... _htHead = NIL line : So this is exactly what I expected. Why does Firefox send the HTTP header, but not the following

Re: jQuery again

2008-10-05 Thread Henrik Sarvell
If the above simple example is not working either for for instance Alex maybe? Then obviously something needs to be changed in either jQuery or the Pico server to make them play well, the question is where and what and which needs fewest changes? Unfortunately I'm sorely lacking in all areas

Re: jQuery again

2008-10-05 Thread Henrik Sarvell
I just did a very basic test, the javascript: function ajaxFunction(){ var xmlHttp; try{ xmlHttp = new XMLHttpRequest(); }catch (e){ try{ xmlHttp = new ActiveXObject(Msxml2.XMLHTTP); }catch (e){ try{ xmlHttp = new ActiveXObject(Microsoft.XMLHTTP);

Re: jQuery again

2008-10-05 Thread Alexander Burger
Hi Henrik, The above works just fine, however when changing the GET to POST I run in to the same stalling problem as I did before. Is there a reason why xmlHttp.open(GET, http://localhost/@ajaxTest;, true); xmlHttp.send(null); When you changed GET to POST, did you also make sure to

Re: jQuery again

2008-10-05 Thread Henrik Sarvell
I just changed the original example to: $(document).ready(function(){ $(.articles_link).css('cursor', 'pointer').click(function(){ $.get(@ajaxTest, {jquerytest: test}, function(res){ $(.middle_content).html(res); }); }); }); Not surprisingly it works too, the only difference is

Re: jQuery again

2008-10-05 Thread Henrik Sarvell
Yes it does, but when changing the ajaxTest function to: (de ajaxTest () (httpHead text/plain; charset=utf-8) (ht:Out T (ht:Prin (pack Result: (get 'jquerytest 'http) I only get Result: in the alert box, and firebug does not show any POST variables at all either.

Re: jQuery again

2008-10-05 Thread Henrik Sarvell
Disregard my prior post, I had forgotten to change the GET to POST. --=_Part_47580_21775726.1223270082765 Content-Type: text/html; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Content-Disposition: inline div dir=ltrDisregard my prior post, I had forgotten to change the GET to

Re: jQuery again

2008-09-28 Thread Henrik Sarvell
I'm still getting exactly the same problem, it just stalls without returning anything, ie Response: Loading... in Firebug. As far as I know this should simply work in the same way a POSTed form does, I know you use Ajax in the JS form logic so there is nothing in the Pico server that is stopping

Re: jQuery again

2008-09-25 Thread Alexander Burger
Hi Henrik, nice but now we have something simpler, a POST on the same domain, i.e. http://localhost:8080. I observed similar problems when sending a POST to the lib/form.l framework. There it works, however, because that framework falls back to a (non-Ajax) HTTP-POST when the first try fail.