How to add JavaCript code to online map in ArcGIS Online

1944
6
10-23-2017 04:16 AM
BrankoIlic2
New Contributor

Hi,
I have created web page with ArcGIS  map, and done everything needed with ArcGIS API for JavaScript, but now is demand to make it all in online map in ArcGIS Online development account.
Is there a way to add JavaCript code which works with ArcGIS API for JavaScript, to new online map in ArcGIS Online?
Regards,
Branko Ilic

0 Kudos
6 Replies
BrankoIlic2
New Contributor

Nobody?
Can it be done, just Yes or No?
Can I add JavaScript code on map in ArcGIS Pro?

0 Kudos
XanderBakker
Esri Esteemed Contributor

Normally you will consume a web map hosted in ArcGIS Online by one of the many templates or solutions ArcGIS Online offers. The moment you start modifying or extending functionality you will most likely download the template or solution and host it on your web server. 

Can you elaborate a little more about what you specifically need in terms of funcionality?

BrankoIlic2
New Contributor

Thanks for the answer.
I thought that web maps hosted in ArcGIS Online are also using ArcGIS API for JavaScript, so I wanted to use ArcGIS API for JavaScript directly in the web maps hosted in ArcGIS.
But now I suspect that it is not possible.

0 Kudos
XanderBakker
Esri Esteemed Contributor

What funcionality would you like to add? There are some great things you can configure with the Web AppBuilder for instance. See: Web AppBuilder for ArcGIS | ArcGIS 

0 Kudos
BrankoIlic2
New Contributor

I have tried Web AppBuilder for ArcGIS | ArcGIS but it gives me only options that I already have in ArcGIS Online.
I wanted to host my code in ArcGIS Online, because it is just a web map with more layers. Hosting on ArcGIS Online is my final task, and I have already made whole map with all layers.
If it is not possible, one of my problems is how to show data from more feature layers in popup of one layer, in ArcGIS Online web map?
Can you help me with that, Is it possible at all?

0 Kudos
XanderBakker
Esri Esteemed Contributor

If you need to customize an app, you will need to download the code, adapt it and publish or your own web server. Using the Web AppBuilder developer edition would be the way to go. There is a group dedicated to custom widgets: Web AppBuilder Custom Widgets where you can find example of very useful widgets ready to deploy on your server. An example is Identify Widget Version 2.5.0.1 - 08/16/2017  created by rscheitlin  which shows how to obtain the results of an identify for multiple layers in a single widget.

0 Kudos