Google Street View Widget 2.1 - 08/29/16

60602
244
12-31-2014 11:01 AM

Google Street View Widget 2.1 - 08/29/16

All after much back and forth with different people and what now seems to be legitimate email traffic with the Google Maps API Team. It is now apparent that this widget does NOT conform to the Google Maps API Terms of Service. Due to this fact, this widget download will be removed and the live preview site will be un-accessible.  It is my recommendation that all users of this widget immediately remove the widget from their WAB site and discontinue use of this widget. The only way it seems currently to be compliant with the TOS is to not have a (non-Google) map visible at all in the app which is of no use at all to us esri users. I find it hard to understand how the Worlds leader in GIS technology and Google can not come to terms on the use of StreetView panoramas with esri basemaps, but it is what it is. So after years of this widget being used by hundreds of users around the world we must say good-bye.

Here is another widget for the Web App Builder.

Web AppBuilder for ArcGIS | Help - Google Street View widget

List of the latest enhancements and changes:

  1. Updated for WAB 2.1

List of older enhancements and changes:

  1. Widget no longer open the street view html window automatically on open.
  2. Prevent popup check from firing multiple times.
  3. Removed sensor portion of the StreetView code as Google has depreciated it.
  4. Minor configuration UI changes.
  5. Widget code updated to work with all the new themes and their style colors.
  6. Fixed issue with maps whose spatial reference was not 4326 or 102100

Features:

  • This widget conforms to the Google Terms of Use (TOS) agreement
  • Widget allows configuration of Google Street View Panorama Options
  • Widget provides drag and drop support
  • Widget provides graphical feedback on the map when changes are made to the Street View Panorama window
  • This widget displays the Google Street View Panorama in a popup browser window as to not violate the Google TOS agreement
Attachments
Comments

i pasted my key in when configuring the app in the builder.

seems to be working fine.

George,

   If you are talking about an app that you are working with in WAB Dev (i.e. one not yet deployed to your web server) than it is best to leave the Google API Key blank.

I'm working in WAB developer, I can get the app streetview popup widget to work, but not the google streetview. If I do deploy to my web server do I then need the api key?

Yes once you deploy.

Thanks.

Wait...there are other themes?

Yeah...I guess I didn't test with other themes.

Thanks for the update Robert.

Is there the ability to reduce the number of times this widget is calling the API so as not to require payment for requests exceeding the amount listed (which I think is 25k per day)?

Nope, the widget is not making more requests than needed to my knowledge.

Daniel,

   Can you tell me the error info that will be displayed in your browsers web console?

Anyway to change the location of the popup window? The street view window covers the "little man" when the widget is opened in the foldable theme..  Might be confusing to users.

Leo,

   I am unaware of a good way to do that.

Is there a way to change the text that appears in the widget window?  I want to add some tips and clarification for people who may find it finicky/new.  I have opened a lot of the files (if not all of them) and I cannot find it.

Also, it would be nice to add a "clear" button to remove the Google Guy from the map easily.  Closing the widget window doesn't clear the result, and sometimes 2 guys will be on the map.  (The first location was a test, grayed out because not on a street. I closed the widget window which took him off the map. When I opened the widget back up, gray guy reappeared, but I could still place a new one.)  Other than that minor inconvenience, this widget is awesome, thank you!

I just found the instructions in the strings.js file!!!  (Thank you robot YouTube video!)

Emma,

   After some testing I can not find a situation where the google pin man does not get removed from the map when a new one is dropped on the map.

Hi Robert- Do you have instructions to add this custom widget folder to the Portal server so it is available to use with the embedded version of the Portal Webapp builder ?

Sowjanya,

   Custom widgets are not supported in the embedded version of the Portal Webapp builder.

Here is a blog that details this:

Clarifying 3 questions about Web AppBuilder for ArcGIS | ArcGIS Blog

Thanks Robert.

Hello,

with 1.2 version of WebApp Builder I have a issue: "onClose" doesn't work (the debugger never enter in this this method) and it is not possible to clear the icon on the map when I close the widget.

Why? Is there a workaround?

I only unzip the plugin into the widgets folder and use it in my application.

Have I do anything else?

Thanks

Fabio

Fabio,

   This is a known bug for WAB in certain themes. See this thread for a work around:

Widget's callback functions in Launchpad theme not working?

Amazing work!

@Robert - if I have to plug in a new browser API key for the widget to work in a PROD environment ( after deployment), can I replace the key in "googleapikey" portion of the config.json file of the widget?

Is there any other location that I need to insert the new key

Sowjanya,

   Nope the only place is the "config_Google Street View.json"

This may be a bit of a basic question, but looking at Q2 on the link provided above, do you have a resource that would show a step-by-step on how to: "download the code for the web app and deploy it on your own web server. Then you could add your own custom widgets within the web app by modifying/editing the app’s configuration files." I'm pretty new to using ArcGIS Online, and the weapps, and would really like to add this functionality to my existing webmap. Any insight you have would be helpful.

Matthew, if you are looking to download an get started in the Web Appbuilder developer edition, besides the link to the help that Robert provided, you can check out my Web AppBuilder Developer Edition - Customization Resource List​ which has links to download and help in getting it installed and setup.

Robert Scheitlin, GISP

We love this widget. I had a comment by someone that I thought would be worth sharing. When you click on the street view widget and drag the Google hang man out, a new window pops up.

How difficult would it be to have the street view open up in the white space of the widget pane instead of a different window? On a desktop it isn't a problem, but on a mobile device, for many layman users, they don't realize street view opens up in a different tab of their browser.

Jordan,

    Based on MY understanding of the Google StreetView Terms of Use (TOU) the way I have it setup to open a separate window and have all the google trade marking is the only way to stay in compliance with the TOU. Some disagree but as the widget developer this is my position and it will always remain in a separate window.

Ok. You know better than I do. Thanks!

Robert

i have an issue with the google streetview

i am trying to use in on an iPad.

the browser is non-standard as we are using the Citrix WorXweb so the issue might be with that but maybe you have an idea..here is the scenario...

when i click the icon to start the streetmap widget i see the box that has the header 'google street view' but then very quickly the window that on the PC is blank until i drag the google person to a street opens, but  and hers is the problem, what it does is open in the same 'tab' as the viewer,

as a result i just see a blank box with a url like this:

https://gisportal.mwra.net/gisviewer/widgets/streetview/images/icon.png

and the viewer has been replaced.

i guess the question is:

do you know of a way to alter the code so that this window would open in a new tab?

Glenn,

   When testing on an iPad I found that dragging the Google Street View man is very problematic. what does work is click on the Street View Man and then click on the map and voila it works, at least in normal safari on an iPad.

thanks for the tip

but i am not able to drag the little guy.

what is happening is that the view window is replacing the viewer in the open tab,

i am hoping you might have a way to force that window to open in a new tab.

Glenn,

To clarify the dragging is problematic on iPad so instead click on the little man and then click on the map (do not attempt to drag). When you attempt to drag it is selecting the Google Street View Man Image and thinks that you want to open that image in the current window when you drop it.

i'm sorry i am not being clear

when i click the icon to open the streetview widget

i dont get a chance to use the little man because the window where the street view would appear replaces the viewer. i can see the widget opening briefly but then the second window opens and replaces the viewer and the widgets with the blank window.

Glenn,

   In my testing on an iPad the google street view window opens in a new tab and I have to switch between tab to work with the map or the street view. You can test this by opening my Live Preview Site (at the top of this page) for this widget on your iPad. If the Live Preview site works as I am reporting then the issue is your Citrix WorXweb and I am not sure I can help.

yes it is the citrix browser.

i was hoping you had a way to force it to open a new tab.

thanks for taking the time to discuss it.

Glenn,

   I am opening in a new window/tab in my code using "_blank" or a new named window called "StreetView" and the document.parentWindow.open or window.open methods depending on the browsers feature support. So I am not sure and have no experience with citrix browser as to why they are ignoring this standard browser convention.

Hi Robert,

I know this is a elementary question, but I'm actually having trouble adding the street view widget to my web app. I download the code attachment from ArcGIS online and then copy your unzipped "StreetView" folder in the widget folder of the app code. I then configure the .json files in the widget folder to read the newly added StreetView folder. I upload my updated code for the web app, but don't see the street view widget in my list of addable widgets when editing the web app. I'm sure I'm missing a step to make the widget appear as an addable option. Any insight would be appreciated. Thanks in advance.

Joe

Joe,

   Some of the step you are saying you took have me scratching my head... To add a custom widget to your WAB install

1. You download the custom widget and extract the contents to your [instal dir]\client\stemapp\widgets folder. That's it. Nothing else to do.

2. If you had WAB open then close it and the CMD window and re-launch the startup.bat.

3. In WAB open your app and you will now see the custom widget listed as an available widget to add to your app.

4. All my widgets have configuration UIs where you do not have to edit .json files manually.

For my Google Street View Widget there is nothing really to change in the UI unless you want to change any of the defaults.

Hope this helps

Thanks Robert. I'm definitely missing something. I'm new the the app builder world. Below is a link to my methodology. Can you please take a look if you have a chance.

Thanks again,

Joe

https://georgetown.org/gis/WebMaps/WidgetMethodology.pdf

Joe,

   Custom widgets can not be added to AGOL hosted WAB apps. If you want to use custom widgets then you have to use WAB Developer version and host your apps on your own web server.

Thank you for the clarification. I'll host the app internally.

On my Ipad streetview was working great, using safari  now i get a message that this site is attempting to open a pop up window with option to allow or block. Even if I allow the streetview does not show up. This just started, using chrome the pop up window opens with  a server not found error.

George,

   Not sure what is going on on your end but I just tested Chrome and Safari on my iPad and all is well.

Thanks Robert, must be wifi network, I will test later on another wifi.

Wish they would add this to AGOL

I am at my wits end why Streetview is being blocked on my pad, I have block ups allowed on Safari,  @Robert Scheitlin your streetview map works on my Ipad. My wab map will not allow streetview to open on the ipad saying this site is attempting to open a pop up window, Block Allow, I allow 3 to 4 times then a separate tab opens with Error Code: 500 internal Server Error, the request was rejected by HTTP Filter.  (12217) I have tried this on other wifi networks and even my home network and get the same error only applicable to my WAB map. I have uninstalled Streetview and reinstalled V1.3 same problem

George,

   Start a new thread with this issue so that I can get you to attach your json file (you can not do that in the comments of a document). Also I will walk you through some other things to check.

Support for hosting web files on google drive ends August 31, 2016

Host web pages with Google Drive - Drive Help

Hi Robert,

Great widget!  It seems to work fine in WebApp 2.0.

I was wondering if you had any plans to update the widget so it's compatible for use in 3D scenes.  Thanks.

Charles,

I have not given it much thought but I will look into it.

Version history
Revision #:
1 of 1
Last update:
‎12-31-2014 11:01 AM
Updated by: