Settings Page Configuration Help

903
3
Jump to solution
09-20-2016 07:09 AM
JacobNosal
New Contributor III

Hello all,

I am working on creating a custom widget that allows a user to preview images of features on the web map. The webmap is hosted through Portal backed by ArcGIS for Server. The problem that I'm currently working through has to do with the configurability of the map and designating layers by url (because I can't assume they will be in any specific order). I am trying to save the urls to the config.json file in my widget, but am having trouble with the dojo.request.xhr.() call as the config.json is not in the root directory. Is there a better way to approach this?

At a basic level, I'm asking for best practices concerning writing to config.json in settings.js in order to access config.json in widget.js.

Regards,
Jacob Nosal

Tags (1)
0 Kudos
1 Solution
3 Replies
RobertScheitlin__GISP
MVP Emeritus

Jacob,

   The WAB widget base class gives you access to the widgets config.json without the use of a dojo xhr request. You can look at the WAB help docs for info on this or any of the OTB widget for examples of code for this.

JacobNosal
New Contributor III

I've got it working now actually. Can you provide a link to the documentation you are referring to? For posterity's sake.

0 Kudos