Take the 2-minute tour ×
Geographic Information Systems Stack Exchange is a question and answer site for cartographers, geographers and GIS professionals. It's 100% free, no registration required.

I am passing five featuresets to a ArcGIS Server Javascript API. When I do that I get 'Deferred Object not defined error'. Then I tried to use dojo.Deferred(). At that point the error goes away. But nothing happens. In Fidller, no request information is logged. Then I removed some of the records from the featureset and I can see the request is logged in the fiddler and the request reaches the server. Processing fails, because all required data is not available. Can some one help understand how to setup proxy server in ArcGIS Server 10.1 and use POST request it in JS API for Synchronous and Asynchronous Geoprocessing? Also I can someone show me how to use dojo.deferred() when using GP Service.

Thanks Cyril

share|improve this question
    
Worth checking out: maps.rosreestr.ru/arcgis_js_api/sdk/help/jsapi/… See the {useProxy: true , usePost: true} options. –  Leniel Macaferi May 1 at 0:48

1 Answer 1

You need a proxy page in mainly two conditions:

  1. The application uses GET requests that exceed 2048 characters.

  2. The JavaScript makes a HTTP (besides Images & Scripts) request to a server on a different domain, which does not support JSONP.

You are facing the first problem:

I would request you to look at the following page: Using the proxy page

This page will give you basic information about a proxy page, as well as how to set it up.

You do not need to explicitly make the request a POST request if you are using ArcGIS API classes. They automatically become a POST request whenever needed.

And you don't actually need a dojo.deferred(). If you have set up the handlers properly, it should work fine.

share|improve this answer
1  
Thanks you Devdatta, I will review the URL that you listed. –  Cyril Feb 14 '13 at 19:02

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.