[fusion-users] fusion widget / invokeurl questions
Yewondwossen Assefa
yassefa at dmsolutions.ca
Wed Mar 26 10:51:37 EDT 2008
larry white wrote:
> Not sure if this is the appropriate list for the following questions -
> maybe dev list?
>
I think this list appropriate.
> Perhaps I'm missing something obvious, but I'm having difficulty
> figuring out how to migrate custom tasks from a MapGuide ajaxviewer app
> to a Fusion app - would like to create analogous widgets / InvokeUrl
> calls in Fusion.
>
> For example, a 'quick view'-type function, that contains a list of links
> to places (click the link and the map will recenter and zoom to the
> point) or a geocoding function.
> MapGuide ajaxviewer uses the 'gotopoint.php' file to accomplish these
> things.
>
>
> I've gone through the code for most of the existing widgets, but can't
> find much that seems to helps me with Invoke URL calls.
> So, my initial questions:
>
> 1) Are there examples of InvokeURL usage? (I couldn't find any examples
> in the widgets dir or in the documentation)
>
> 2) Is there an existing, similar file/widget that accomplishes the
> 'gotopoint.php' capability?
>
> 3) If it doesn't exist, where would one start in building such a capability?
> Should this be an 'InvokeURL' call? a Widget?
> How/where to build 'gotopoint' logic so that it can be used in
> multiple instances/widgets (eg., quick-view and geocoding)
>
> 4) How to communicate between task pane and map? how to pass
> javascript-y things between task pane and map using widgets and InvokeURL
> - which files to include
> - what methods/functions/calls to use
>
>
I have not used much the InvokeURL so I can cot comment on it. But for
the task that you want to accomplish (quickzoom), the simplest way I
thing would be to just have a custom javascript code to do it. Something
like this could work:
function ZoomToPoint(x, y)
{
var oMap = Fusion.getMapByIndice(0);
oMap.zoom(x, y, 1);
}
I find it a lot easier to use the Fusion api for simple interactions
that creating widgets. There is an effort going on to add more
documentation to fusion and hopefully a more complete API documentation
would be available.
Hope it helps.
Best Regards
> thanks in advance....
>
> -- larry white
>
--
----------------------------------------------------------------
Assefa Yewondwossen
Software Analyst
Email: assefa at dmsolutions.ca
http://www.dmsolutions.ca/
Phone: (613) 565-5056 (ext 14)
Fax: (613) 565-0925
----------------------------------------------------------------
More information about the fusion-users
mailing list