POST
|
Riyas I tested your code and it seems my problem has gone a way. Here is the jsfiddle I created http://jsfiddle.net/hkr7cn1x/ I have a few questions. In this line of code: http://sampleserver6.arcgisonline.com/arcgis/rest/services/Utilities/Geometry/GeometryServer/project?f=json&outSR=102100&inSR=4326&geometries=%7B%22geometryType%22%3A%22esriGeometryPoint%22%2C%22geometries%22%3A%5B%7B%22x%22%3A174.10266423100921%2C%22y%22%3A-39.04732347299239%2C%22spatialReference%22%3A%7B%22wkid%22%3A4326%7D%7D%2C%7B%22x%22%3A174.10538328709313%2C%22y%22%3A-39.04732347299239%2C%22spatialReference%22%3A%7B%22wkid%22%3A4326%7D%7D%2C%7B%22x%22%3A174.10538328709313%2C%22y%22%3A-39.043794057776715%2C%22spatialReference%22%3A%7B%22wkid%22%3A4326%7D%7D%2C%7B%22x%22%3A174.10266423100921%2C%22y%22%3A-39.043794057776715%2C%22spatialReference%22%3A%7B%22wkid%22%3A4326%7D%7D%5D%7D I just replace this line with this one: http://sampleserver6.arcgisonline.com/arcgis/rest/services/Utilities/Geometry/GeometryServer This is now working fine. I got another developer develop this for me and here are two lines from his code: esriConfig.defaults.io.alwaysUseProxy = false; geometryService = new GeometryService("http://sampleserver1.arcgisonline.com/ArcGIS/rest/services/Geometry/GeometryServer"); Perhaps creating the proxy is way to go. If I don't want to use sampleserver, is there another server that I can use in production environment? Robert, in the previous comment share this link: http://tasks.arcgisonline.com/ArcGIS/rest/services/Geometry/GeometryServer I still got the cross site scripting issue. How can I modify this link? Thanks a lot.
... View more
08-14-2014
04:42 PM
|
0
|
0
|
705
|
POST
|
Robert, thanks for the link. It seems to work fine now. The map is loading fine. But when I inspected the code, I got this error. Any idea how to fix this? XMLHttpRequest cannot load http://tasks.arcgisonline.com/ArcGIS/rest/info?f=json. No 'Access-Control-Allow-Origin' header is present on the requested resource. Origin 'http://example.com' is therefore not allowed access.
... View more
08-14-2014
04:21 PM
|
0
|
1
|
705
|
POST
|
Thanks Robert. In my case, I don't need that level of map yet. I just need a generic map which is pulled using the javascript api. I then projected my drawing on the fly. So actually I don't need to host any data don't I? My only concern now is the use of services on sampleserver. I know it is sampleserver, so there is limitations. Based on the article you shared, the api should be free since it is for non commercial use. Just wondering how I can avoid relying on the sampleserver.
... View more
08-14-2014
06:57 AM
|
0
|
3
|
705
|
POST
|
Just one question about hosting organization data. What kind of data is it? What I have in mind is perhaps my company needs to some map of its own and then it would need to host that map data. But in my case, I don't need that yet. I only need the basemap from arcmap, which will be pull using the javascript api. So is it this data that you are referring to?
... View more
08-14-2014
06:36 AM
|
0
|
5
|
1426
|
POST
|
Robert, I am still learning this. So please be patient with me here. I used asp.net and I learned how to code through the sample codes in ArcGIS API for JavaScript. I have not run across any requirement about ArcGIS organizational account. Could you please explain a little bit more? What kind of organization data are we talking about here? All I need for my web application is the basemap and arcgis services. Do I need to host any data in this case? I would appreciate it if you could give me some real examples just to clear this up. Thanks.
... View more
08-14-2014
05:58 AM
|
0
|
7
|
1426
|
POST
|
Hello everyone it's my first time to deal with publishing a web application with arcgis feature, so please give me advice. I have done some research and found that there are a few free services such as http://www.arcgis.com/explorer/ or https://www.arcgis.com/home/. I know there are limitations to what I can do with these free services. But if it meets my needs, I really want to stick to it just to save cost since my company is still in testing phase. So here are the requirements: 1. I need a base map 2. I need feature layer 3. I need popup infowindows I got a developer did the development work for me. And in his code, I can see these: require([ "esri/map", "esri/layers/FeatureLayer", "esri/graphic", "esri/dijit/PopupTemplate", "esri/symbols/SimpleMarkerSymbol", "esri/symbols/SimpleLineSymbol", "esri/symbols/SimpleFillSymbol", "esri/tasks/FeatureSet", "dojo/on", "dojo/dom", "esri/renderers/SimpleRenderer", "esri/InfoTemplate", "esri/geometry/Point", "esri/geometry/Extent", "esri/SpatialReference", "esri/tasks/GeometryService", "esri/tasks/ProjectParameters", "esri/tasks/query", "esri/symbols/TextSymbol", "esri/layers/LabelLayer", "dojo/_base/Color", "dojo/domReady!"], Based on my description, do you think the free service is enough to meet my needs? If not, do you have any suggestion for me on how I can save? Earlier today, I asked a question about this line: geometryService = new GeometryService("http://sampleserver6.arcgisonline.com/arcgis/rest/services/Utilities/Geometry/GeometryServer"); In production environment, it's not recommended that I use sampleserver. What other options do I have? Thanks.
... View more
08-13-2014
09:13 PM
|
0
|
0
|
2437
|
POST
|
Owen, I inspected element using google chrom and here is the error: XMLHttpRequest cannot load http://sampleserver6.arcgisonline.com/arcgis/rest/services/Utilities/Geomet…43794057776715%2C%22spatialReference%22%3A%7B%22wkid%22%3A4326%7D%7D%5D%7D. The 'Access-Control-Allow-Origin' header has a value 'http://localhost:6179' that is not equal to the supplied origin. Origin 'http://example.com' is therefore not allowed access. The message seems to refer to localhost. Where can I change that?
... View more
08-13-2014
08:07 PM
|
0
|
3
|
705
|
POST
|
Robert, I have a question. I quickly read the document and it seems that I would need my own server machine to host this. Is it correct? If it is the case, then it is a problem for me since I host my site with a hosting service and there is no way they will allow me to do that on their server. Thanks
... View more
08-13-2014
07:49 PM
|
0
|
9
|
1426
|
POST
|
Thanks Robert. That's what I figure. Could you share with me some articles on how I can set this up? I am new to this.
... View more
08-13-2014
07:25 PM
|
0
|
11
|
1426
|
POST
|
Thanks Owen for the reply. I am new to arcgis. I saw the sample code and here is how it uses the service: geometryService = new GeometryService("http://sampleserver6.arcgisonline.com/arcgis/rest/services/Utilities/Geometry/GeometryServer"); I am wondering what you mean by using proxy? Does it mean I can't use the url that way? If so could you point me to the right place? Thanks.
... View more
08-13-2014
07:20 PM
|
0
|
5
|
705
|
POST
|
Hello everyone, I recently publish my site and it was working fine until today. I got this message: http://screencast.com/t/BdTyk4X7 Do you know what it is? How can I fix this? When I run the same code locally, it is working fine. Thanks
... View more
08-13-2014
04:16 PM
|
0
|
20
|
6708
|
POST
|
Yes exactly Jake. One tab for information and one tab for the grid. But the problem I am having now is information tab is loaded on page load (this is fine) while the grid is built on the fly. So when a button is clicked, I need to insert the grid information into tab2. The example you share is quite good but it's side content not popup. http://developers.arcgis.com/javascript/samples/layout_MapContainerSplitLeft/ And also I tried to click on the map but it seems the second tab doesn't show anything. Do you know where I can have a look at the code example of that one? Thanks.
... View more
08-07-2014
04:52 AM
|
0
|
1
|
753
|
POST
|
Thank you Jake. That's what I am looking for. But I have another question. If you look at my code above, I built the info windows when the page loaded. But I need to somehow connect this info windows with another div containing a grid that I built on the fly. Do you think this can be done? Cheers.
... View more
08-07-2014
04:35 AM
|
0
|
3
|
753
|
POST
|
Hello everyone, I would like to display popup info windows into two tabs. Could someone point to some links where I can refer to? I have tried jquery UI, here is how I built the info windows
var div = "<div>";
var table = "<table border='1' width=300>";
for (prop in graphic.attributes) {
table += "<tr><td>" + prop + "</td><td><b>" + graphic.attributes[prop] + "</b></td></tr>";
}
table += "</table>";
I tried to build it this way, and it didn't work:
var div = "<div id='tabs'> <ul><li><a href='#fragment-1'><span>Layers</span></a></li><li><a href='#fragment-2'><span>Query</span></a></li></ul>";
var table = " <div id='#fragment-1'><table border='1' width=300>";
for (prop in graphic.attributes) {
table += "<tr><td>" + prop + "</td><td><b>" + graphic.attributes[prop] + "</b></td></tr>";
}
table += "</table></div><div id='#fragment-2'>test</div></div>";
Here is my jquery code:
<script>
$("#tabs").tabs({ active: 1 });
</script>
Thanks.
... View more
08-07-2014
03:36 AM
|
0
|
5
|
2606
|
Online Status |
Offline
|
Date Last Visited |
11-11-2020
02:23 AM
|