Community
All Communities
Products
ArcGIS Pro
ArcGIS Survey123
ArcGIS Online
ArcGIS Enterprise
Data Management
ArcGIS Experience Builder
Geoprocessing
ArcGIS Web AppBuilder
ArcGIS Dashboards
ArcGIS Field Maps
ArcGIS StoryMaps
All Products Communities
Industries
Education
Water Resources
State & Local Government
Transportation
Gas and Pipeline
Water Utilities
Roads and Highways
Telecommunications
Natural Resources
Electric
Imagery and Remote Sensing Insights (IRIS) COP
All Industries Communities
Developers
Python
JavaScript Maps SDK
Native Maps SDKs
ArcGIS API for Python
ArcGIS Pro SDK
ArcObjects SDK
Developers - General
ArcGIS REST APIs and Services
ArcGIS Online Developers
Game Engine Maps SDKs
File Geodatabase API
All Developers Communities
Global
Comunidad Esri Colombia - Ecuador - Panamá
ArcGIS 開発者コミュニティ
Czech GIS
ArcNesia
Europe
Esri India
Americas
Asia Pacific
Comunidad GEOTEC
GeoDev Germany
ArcGIS Content - Esri Nederland
All Global Communities
All Communities
Developers
User Groups
Industries
Services
Community Resources
Global
Events
Learning
Networks
ArcGIS Topics
Products
View All Communities
ArcGIS Ideas
GIS Life
Community Resources
Community Help Documents
Community Blog
Community Feedback
Member Introductions
All Community Resources
Sign In
cancel
Turn on suggestions
Auto-suggest helps you quickly narrow down your search results by suggesting possible matches as you type.
Showing results for
Show
only
|
Search instead for
Did you mean:
Cancel
Home
:
All Communities
:
Developers
:
JavaScript Maps SDK
:
JavaScript Maps SDK Questions
:
Re: Editing map using Proxy
Options
Subscribe to RSS Feed
Mark Topic as New
Mark Topic as Read
Float this Topic for Current User
Bookmark
Subscribe
Mute
Printer Friendly Page
Select to view content in your preferred language
Translate Now
Editing map using Proxy
Subscribe
6942
20
09-27-2011 08:10 PM
by
shwetakunjadia
Emerging Contributor
09-27-2011
08:10 PM
Mark as New
Bookmark
Subscribe
Mute
Subscribe to RSS Feed
Permalink
Print
Hi All,
I am using arcgis server 10..
Javascript api 2.5
Editing map sample
I followed all steps to create Proxy on arcgis server..
I am not able to add any feature on map
😞
Error on fire bug:
Error: Unable to load
http://arcgis:8399/proxy/proxy.jsp?http://arcgis:8399/arcgis/rest/services/app1/FeatureServer/18/app...
status:0
()?v=2.5 (line 14)
undefined = "[object Object]"
()?v=2.5 (line 14)
()?v=2.5 (line 14)
undefined = "-2"
(function(){var _1=null;if((_1||(typeo...etTimeout(dojo._loadInit,100);}})();
Please help me where i am going wrong ???
Tags
(2)
Tags:
javascript
web_developers
Reply
0
Kudos
All Posts
Previous Topic
Next Topic
20 Replies
by
shwetakunjadia
Emerging Contributor
10-11-2011
08:12 PM
Mark as New
Bookmark
Subscribe
Mute
Subscribe to RSS Feed
Permalink
Print
Can anyone tell me where to set proxy.jsp ??
on server or on local machine??
Please someone help me.....
Thanks,
Shweta
Reply
0
Kudos
by
derekswingley1
Deactivated User
10-11-2011
11:28 PM
Mark as New
Bookmark
Subscribe
Mute
Subscribe to RSS Feed
Permalink
Print
Your proxy has to live on the same server as your JS API app.
Are you able to contact support for help? This is something that they should be able to walk you through.
Reply
0
Kudos
by
shwetakunjadia
Emerging Contributor
10-12-2011
07:10 PM
Mark as New
Bookmark
Subscribe
Mute
Subscribe to RSS Feed
Permalink
Print
yes both are on the same server still not getting
😞
Thanks,
Shweta
Reply
0
Kudos
by
derekswingley1
Deactivated User
10-13-2011
07:06 AM
Mark as New
Bookmark
Subscribe
Mute
Subscribe to RSS Feed
Permalink
Print
Please contact support if you're unable to get it working by following the steps outlined here:
http://help.arcgis.com/en/webapi/javascript/arcgis/help/jshelp/ags_proxy.htm
Reply
0
Kudos
by
shwetakunjadia
Emerging Contributor
10-13-2011
06:04 PM
Mark as New
Bookmark
Subscribe
Mute
Subscribe to RSS Feed
Permalink
Print
Is it Free to contact support team ???
Reply
0
Kudos
by
derekswingley1
Deactivated User
10-13-2011
06:58 PM
Mark as New
Bookmark
Subscribe
Mute
Subscribe to RSS Feed
Permalink
Print
Unfortunately, no.
Reply
0
Kudos
by
shwetakunjadia
Emerging Contributor
10-14-2011
12:04 AM
Mark as New
Bookmark
Subscribe
Mute
Subscribe to RSS Feed
Permalink
Print
😞
Is it necessary to set proxy page while i m edit/add feature on layer ??
Is there any other way in java script api ???
Thanks,
Shweta
Reply
0
Kudos
by
nicogis
MVP Alum
10-14-2011
12:18 AM
Mark as New
Bookmark
Subscribe
Mute
Subscribe to RSS Feed
Permalink
Print
- have you tried insert feature from rest page?
- have you configurated serverUrls in page proxy?
- can you do debug on page.jsp calling page
http://arcgis:8399/proxy/proxy.jsp?h.../18/applyEdits
?
Reply
0
Kudos
by
shwetakunjadia
Emerging Contributor
11-08-2011
08:26 PM
Mark as New
Bookmark
Subscribe
Mute
Subscribe to RSS Feed
Permalink
Print
Hello Alll,
Can anyone tell me is therr anything wrong in proxy.jsp file??
Code:
<%@page session="false"%>
<%@page import="java.net.*,java.io.*" %>
<%!
String[] serverUrls = {
"
http://server:8399/arcgis/rest/services/
"
};
%>
<%
try {
String reqUrl = request.getQueryString();
boolean allowed = false;
String token = null;
for(String surl : serverUrls)
{
String[] stokens = surl.split("\\s*,\\s*");
if(reqUrl.toLowerCase().contains(stokens[0].toLowerCase())) {
allowed = true;
if(stokens.length >= 2 && stokens[1].length() > 0)
token = stokens[1];
break;
}
}
if(!allowed) {
response.setStatus(403);
return;
}
if(token != null) {
reqUrl = reqUrl + (reqUrl.indexOf("?") > -1 ? "&" : "?") + "token=" + token;
}
URL url = new URL(request.getQueryString());
HttpURLConnection con = (HttpURLConnection)url.openConnection();
con.setDoOutput(true);
con.setRequestMethod(request.getMethod());
int clength = request.getContentLength();
if(clength > 0) {
con.setDoInput(true);
InputStream istream = request.getInputStream();
OutputStream os = con.getOutputStream();
final int length = 5000;
byte[] bytes = new byte[length];
int bytesRead = 0;
while ((bytesRead = istream.read(bytes, 0, length)) > 0) {
os.write(bytes, 0, bytesRead);
}
}
out.clear();
out = pageContext.pushBody();
OutputStream ostream = response.getOutputStream();
response.setContentType(con.getContentType());
InputStream in = con.getInputStream();
final int length = 5000;
byte[] bytes = new byte[length];
int bytesRead = 0;
while ((bytesRead = in.read(bytes, 0, length)) > 0) {
ostream.write(bytes, 0, bytesRead);
}
} catch(Exception e) {
response.setStatus(500);
}
%>
Please help me i want it to be working as soon as possible
😞
Thanks,
Shweta
Reply
0
Kudos
Post Reply
«
Previous
1
2
3
Next
»
«
Previous
1
2
3
Next
»