[fusion-users] calling query() method from another window

Tómas Guðmundsson tomas at snertill.is
Fri Jun 6 05:30:49 EDT 2008


In related matters, does anyone know of a resource that can tell me how to query? I do have a certain layer or a certain map I want to query against, but I don't know the format of a query string for map.query(). I see that Paul sent some options so maybe I need an options variable to search by ? Is there anywhere in the fusion code where this is done so I can see what parameters options has ?

Rgds
Tómas

-----Original Message-----
From: fusion-users-bounces at lists.osgeo.org [mailto:fusion-users-bounces at lists.osgeo.org] On Behalf Of Paul Spencer
Sent: 6. júní 2008 01:37
To: Vitor Fortunato
Cc: fusion-users at lists.osgeo.org
Subject: Re: [fusion-users] calling query() method from another window

Hi Vitor,

you need to get the map in a slightly different way:

var map = window.opener.Fusion.getWidgetById('map'); //or whatever  
your map div id is
map.query(options);

Cheers

Paul

On 5-Jun-08, at 8:40 PM, Vitor Fortunato wrote:

> Hi list!
>
> I am trying to call the query() method from a new window opened by a  
> widget.
> In execute method of the widget I have the code bellow:
>
> execute : function() {
>     var Url = 'qb.html';
>     winQb = window.open(Url, 'New window',  
> 'toolbar 
> = 
> no 
> ,menubar 
> = 
> no 
> ,location 
> =no,resizable=yes,status=yes,scrollbars=yes,width=900,height=540');
> }
>
>
> when the widget is executed it pops up a new window. I am trying to  
> execute the query method from this new window. I've tried to code  
> something, but still with no success:
> code of the new window:
> <script>
>     var options = {};
>     options.filter = 'gid in (1, 2, 3)';
>     options.layers = 'Estados';
>
>     window.opener.Fusion.Widget.Map.query(options);
>
>     //also tried to get the caller widget:
>     // var myWidObj = new window.opener.Fusion.Widget.Pqb();
> </script>
>
> thanks in advance
> _______________________________________________
> fusion-users mailing list
> fusion-users at lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/fusion-users


__________________________________________

    Paul Spencer
    Chief Technology Officer
    DM Solutions Group Inc
    http://www.dmsolutions.ca/

_______________________________________________
fusion-users mailing list
fusion-users at lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/fusion-users


More information about the fusion-users mailing list