Public Maps Gallery template version 1.4  --Opening post

12453
175
11-22-2011 02:57 PM
Esriwebmap
New Contributor III


Please reply to this opening post to submit questions and comments about the Public Maps Gallery (PMG) template version 1.4.
Tags (2)
0 Kudos
175 Replies
BillEveringham
New Contributor III
I think I know what it is. IE is VERY picky about JSON objects and extra commas. Try removing the last comma in this code:

// LINK 4
 {
  title: "City of Alexandria GIS",
  url: 'http://alexandriava.gov/GIS'
  
 },


Let me know if that works.

Thanks


Thanks... that did the trick
0 Kudos
Esriwebmap
New Contributor III
Thanks... that did the trick


Glad that worked 😄
0 Kudos
MichalGasparovic
New Contributor III
Hi, thanks for the "gallery application", but is there any chance to use this for the "private" maps and groups?
Thank you.

EDIT : meanwhile I've just modified the source code to bypass the arcgisonline and read the data from my rest endpoints straightaway
0 Kudos
ScottTometich
New Contributor III
I would like to include static PDF maps in this gallery, but ArcGIS.com does not allow this file type.  Is there a way that I could include PDF maps?
0 Kudos
Esriwebmap
New Contributor III
I would like to include static PDF maps in this gallery, but ArcGIS.com does not allow this file type.  Is there a way that I could include PDF maps?


Hi Scott,

I think you can add an item in ArcGis.com as an external application and then put the link to the PDF if you have it on your own server. I think that's the solution we've used before. I don't think it will let you upload a PDF though.
0 Kudos
Esriwebmap
New Contributor III
Hi, thanks for the "gallery application", but is there any chance to use this for the "private" maps and groups?
Thank you.

EDIT : meanwhile I've just modified the source code to bypass the arcgisonline and read the data from my rest endpoints straightaway


Cool. Feel free to modify it however you'd like.

You may be able to get it to work with private maps and groups using the identity manager. I know it works for secured services and I think it works for ArcGIS.com private content. We don't have any plans on adding this to this template at this time, that may change, but you're more than welcome to implement it.

http://help.arcgis.com/en/webapi/javascript/arcgis/help/jsapi_start.htm#jsapi/identitymanager.htm
0 Kudos
MichalGasparovic
New Contributor III
mate you are a legend if this works. will give it a go now. thanks for the link I didn't know I could use that class for ArcGIS.com content as I never cared. but now it's a somewhat different situation. cheers

Cool. Feel free to modify it however you'd like.

You may be able to get it to work with private maps and groups using the identity manager. I know it works for secured services and I think it works for ArcGIS.com private content. We don't have any plans on adding this to this template at this time, that may change, but you're more than welcome to implement it.

http://help.arcgis.com/en/webapi/javascript/arcgis/help/jsapi_start.htm#jsapi/identitymanager.htm
0 Kudos
JonBeets1
New Contributor II
Hi, thanks for the "gallery application", but is there any chance to use this for the "private" maps and groups? 
Thank you. 

EDIT : meanwhile I've just modified the source code to bypass the arcgisonline and read the data from my rest endpoints straightaway


Could you tell me how you did this or do you have a template I can use? Here is my email Jon.Beets@us.af.mil

Thanks...
0 Kudos
MichalGasparovic
New Contributor III
Could you tell me how you did this or do you have a template I can use? Here is my email   Jon.Beets@us.af.mil

Thanks...


basically you need to replace the webmap object by your own object rather than one that comes from arcgisonline. in layout.js file you need to modify the "initMap()" function.
follow the instructions for "Create a map using json" from here
http://help.arcgis.com/en/webapi/javascript/arcgis/help/jshelp/intro_webmap.html

or see the excerpt. hope that helps
  //CUSTOMWEBMAP
  webmap = {};
  webmap.item = {
   "title":"put in your title",
   "snippet": "?",
   "extent" : [[151.1531, -33.909], [151.2702, -33.8514]]
  }; 

  dojo.byId("title").innerHTML = pmgConfig.title || webmap.item.title;
  // SITE TITLE
  if(pmgConfig.siteTitle){
   pmgConfig.pmgSubTitle = pmgConfig.title || webmap.item.title;
   setPageTitle();
  }
  dojo.byId("subtitle").innerHTML = pmgConfig.subtitle || webmap.item.snippet || "";
  var descriptionInfo = pmgConfig.sidebarContent || webmap.item.description || "";
  dojo.byId("descriptionContent").innerHTML = '<h2>About this map</h2>' + descriptionInfo + '<div class="clear"></div>';  
  
  
  webmap.itemData = {
   "operationalLayers": [{
     "url": "<address to your ags service>",
     "visibility": true,
     "opacity": 1,
     "title": "whatever name"     
   }],
   "baseMap": {
       "baseMapLayers": [{
     "opacity": 0.5,
     "visibility": true,
     "url": "<address to your ags service>"
    }],
     "title": "whatevername"
   },
   "version": "1.1"
  };
  
  var mapDeferred = esri.arcgis.utils.createMap(webmap, "map", {
   mapOptions: {
    slider: false,
    wrapAround180:true,
    nav: false
   },
   ignorePopups:false,
   geometryServiceURL: "http://sampleserver3.arcgisonline.com/ArcGIS/rest/services/Geometry/GeometryServer"
    });
  
  // var mapDeferred = esri.arcgis.utils.createMap(itemInfo, "map", {
   // mapOptions: {
    // slider: false,
    // wrapAround180:true,
    // nav: false
   // },
   // ignorePopups:false,
   // bingMapsKey: pmgConfig.bingMapsKey,
   // geometryServiceURL: "http://sampleserver3.arcgisonline.com/ArcGIS/rest/services/Geometry/GeometryServer"
  // });
0 Kudos
StephanieWidas
New Contributor III
We are unable to open any of the Public Map Galleries that are version 1.4.  We've tried to view Esri's demo site, as well as those posted by users on the forum (Arlington, Rockville, etc.).  When we try to launch the gallery, we just get the loading circle icon and the page never loads


Our IT department was finally able to resolve this issue.  They upgraded IronPort to the latest AsyncOS release (7.1.3-021) and installed the URL filter update package that Cisco just recently released.  We can now view 1.4 map galleries in Internet Explorer (after deleting the cache) as well as in Firefox.

I just wanted to share the resolution in case anyone else experiences the same problem.
0 Kudos