[Cartoweb-users] Cartoweb and Ajax

Simon ORTET simon.ortet at silogic.fr
Mon Jul 23 04:18:18 EDT 2007


Thank for your answer. The functionnalities i need in ajax are 
fullExtent and mapSize.
Well by now i'm trying to implement it on the full extent function. 
Maybe you could tell me wether i took a wrong path.
On the doSubmit function, instead of the myform.submit(); i do a 
x_submitForm(); wich looks like this:

/function x_submitForm(){
  var param = AjaxHandler.buildPostRequest();
  var laRequete = new Ajax.Request('/cw/htdocs/x_aeag.php', {method: 
'post',parameters: param,onComplete: afficherReponse} );

/The file x_aeag.php looks like this:
$_ENV['CW3_PROJECT'] = 'aeag';

header('Content-Type: text/xml');

And then i modified the cartoclient.tpl so it produces an xml stream:
/<?xml version="1.0" encoding="UTF-8"?>/

Now my problem is that cartoweb doesn't produce the full extent map 
image. A new image is yet generated but with still the same extent. I 
can't find why...

Simon Ortet

Oliver Christen a écrit :
> Hi
> Some plugins and maybe some core functionnalities are not compatible 
> with ajax.
> Simply changing the doSubmit function to only return xmlhttprequest 
> (ajax) is probably not a good idea as it will break in the cases said 
> above.
> I would suggest to first identify precisely which functionnalities you 
> use are still using non-ajax mode and then see how to modify these 
> functionnalities so they work with ajax (if possible)
> regards
> Oliver
> ----- Original Message ----- From: "Simon ORTET" <simon.ortet at silogic.fr>
> To: <cartoweb-users at lists.maptools.org>
> Sent: Thursday, July 19, 2007 10:25 AM
> Subject: [Cartoweb-users] Cartoweb and Ajax
>> Hi,
>> I'm trying to set Cartoweb as a full Ajax application. So i try to 
>> change the doSubmit function of dhtmlInit.js to make it send the form 
>> through an ajax function.
>> I'd like to know if someone as already done this work, and if 
>> possible to post the code in the list.
>> Thanks
>> _______________________________________________
>> Cartoweb-users mailing list
>> Cartoweb-users at lists.maptools.org
>> http://lists.maptools.org/mailman/listinfo/cartoweb-users

More information about the Cartoweb-users mailing list