Proxy page in .NET?

836
11
10-07-2013 07:00 AM
ionarawilson1
Regular Contributor II
If my server is .NET (IIS), do I follow the steps to create a proxy page in ASP.NET or Java/JSP

I am creating a javascript web app, but I am not using Visual Studio to create it, just aptana.

http://resources.esri.com/help/9.3/arcgisserver/apis/javascript/arcgis/help/jshelp_start.htm#jshelp/...
0 Kudos
11 Replies
MandeepKaur
New Contributor II

Hey Ionara

Did you get solution for your proxy page. Because I am also doing the same proxy setUp for my arcGIS server for my print functionality (arcGIS 10.1). Please let me know if you find anything.

Thanks

Mandeep

0 Kudos
RobertScheitlin__GISP
MVP Esteemed Contributor

Ionara,

   I use the latest proxy from the resource proxy on github Esri/resource-proxy · GitHub‌ If you are using IIS then just use the .Net proxy. You would only use other versions of the Proxy (like java version) if you where using other webservers besides IIS.

MandeepKaur
New Contributor II

Robert

I am following the readme file for .Net proxy. My webpage is hosted on separate external server and my GIS server has all map services. According to readme file of .net proxy, we should create Application pool in GIS server and then include code in my application. But I read online that you are supposed to keep proxy folder in the same location where your webpage is. I am little confused on how should I proceed further as I am new to esri. Appreciate your help.

Thanks

Mandeep

0 Kudos
RobertScheitlin__GISP
MVP Esteemed Contributor

Mandeep,

  The readme.md under the DotNet talks about

  • Install the contents of the DotNet folder as a .NET Web Application, specifying a .NET 4.0 application pool or later
  • then edit the proxy.config to add serverUrls

  I just created a "proxy" folder under my wwwroot on my webserver set it as an application in IIS (Convert to Application option when you right click on the folder in IIS) and set its application pool to .NET 4.0 or higher as mentioned earlier.

MandeepKaur
New Contributor II

Robert

Thanks. I did create an application pool but still i am not able to see that Print button in my application. And I wanted to ask one more thing, that after setting up proxy we are supposed to check if its working through http://myserver/Proxy/proxy.ashx because I kept my proxy.config and proxy.ashx in Proxy folder in wwwroot. But it gives me error saying that The requested URL /Proxy/proxy.ashx was not found on this server.

Do we need to restart our server for putting proxy in action.

Thanks

Mandeep

0 Kudos
RobertScheitlin__GISP
MVP Esteemed Contributor

Mandeep,  When you added the files to your web server did you actually put those files in a folder called "Proxy"?

0 Kudos
MandeepKaur
New Contributor II

Robert

Yes, I did. I have attached the screenshot for you. Kindly let me know if I am missing anything. Thank youproxy folder.png

0 Kudos
RobertScheitlin__GISP
MVP Esteemed Contributor

Mandeep,

   So if you go to your web browser and type http://localhost/Proxy/proxy.ashx?http://services.arcgisonline.com/ArcGIS/rest/services/?f=pjson‌ in the addressbar to you still get the error that the resource was not found?

MandeepKaur
New Contributor II

Yes, I am sti;; getting the error. My server name is arcgis01.madisoncty.com and it's not able to recognize the Proxy folder at all.

0 Kudos