Select to view content in your preferred language

Pass ???Selection??? parameter Through URL

2473
5
03-02-2012 10:20 AM
jasonflake
Emerging Contributor
Hello all.  Was curious if anyone had any experience they might be willing to share with passing specific selection parameters from one web site into a flex site.  For example, if I wanted to take a parcel number that is obtained within an assessors web site and upon a users click, pass that parcel number to a the GIS departments flex site and have the site select and zoom to said parcel.  Any suggestions or ideas?  Probably going to be something that is outside my level of experience but figured I would pose the question anyway.  I will admit that I am not a developer by any means and work pretty much exclusively through widgets to build most of what I have built.  I have been able to build a link into our assessors site but the link from the assessors site back to the GIS map is much more difficult for me.

Thanks,

Jason
Tags (2)
0 Kudos
5 Replies
KenBuja
MVP Esteemed Contributor
You can easily take a parameter from a URL to do something when opening a flex web site. Here's a sample that shows you how to do that
0 Kudos
RobertScheitlin__GISP
MVP Emeritus
Jason,

   You can also accomplish your exact scenario using the Enhanced Search Widget found here:

http://www.arcgis.com/rc/item.html?id=5d4995ccdb99429185dfd8d8fb2a513e

It allows for url searches of a specific layer and highlight of that layer as well as zooming to the feature and displaying results of the search in the widget. Detailed information on setting up the url search capability can be found i the Enhanced Search Widget URL Search Configuration.pdf inside the download.
0 Kudos
jasonflake
Emerging Contributor
Thanks for the replies/info kenbuja and rscheitlin.  Rscheitlin, I have actually utilized your Enhanced Search widget and it works great.  I will admit that I must have over looked that feature of the widget which you pointed out above.  I appreciate it.  From the looks of it, that is exactly what I would like to do. Thanks again for the help.

Jason
0 Kudos
ShaunWeston
Frequent Contributor
Hi Jason,

I did something similar where a user was looking at a selected property in another web application and when they clicked "GIS Viewer" it will go to my GIS application and zoom to that property. I set this up in the URL, so the link would be gis.viewer.com/?12345. So 12345 is the parcel ID and then I wrote a little code in a locate widget:

    var url:String = ExternalInterface.call("window.location.href.toString");
    var urlArray:Array = url.split("?")


So that's going to split up that url and chuck the parcel ID to urlArray[1];

Then I just set this as the default text in the search box on startup of the Flex Viewer - singleAddressTextItem.text = urlArray[1];

Hope that helps!
0 Kudos
jasonflake
Emerging Contributor
Thanks for the reply Shaun.  It certainly is nice having a place to go for help where there are so many knowledgeable individuals willing to share information.  Thanks again guys.
0 Kudos