<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: FeatureLayer.AddAttachment() does not work properly in ArcGIS JavaScript Maps SDK Questions</title>
    <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/featurelayer-addattachment-does-not-work-properly/m-p/393765#M36333</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;BLOCKQUOTE class="jive-quote"&gt;Hi Shreyas,&lt;BR /&gt;&lt;BR /&gt;Are you aware of any change in attachment option in 10.1, the reason I am asking this is as follows:&lt;BR /&gt; I am trying to upload a image from iOS 5 device to ArcGIS Feature service with help of picup (&lt;A href="http://picupapp.com/"&gt;http://picupapp.com/&lt;/A&gt;).&lt;BR /&gt;With ArcGIS Server 10, I am able to add attachment however, when I point to same service published on ArcGIS Server 10.1 it does not work.&amp;nbsp; &lt;BR /&gt;&lt;BR /&gt;I am attaching the http request captured from wireshark for your reference. I do not see any difference between them but if you have any inputs some direction to solve this please share it with me.&lt;BR /&gt;&lt;BR /&gt;[ATTACH=CONFIG]21133[/ATTACH]&lt;BR /&gt;[ATTACH=CONFIG]21134[/ATTACH]&lt;BR /&gt;&lt;BR /&gt;Thanks,&lt;BR /&gt;Rahul&lt;/BLOCKQUOTE&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I never worked on &lt;/SPAN&gt;&lt;A href="http://picupapp.com/"&gt;http://picupapp.com/&lt;/A&gt;&lt;SPAN&gt; ,so I cannot really comment on this one. &lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;There was a new parameter added called as gdbVersion at 10.1 for &lt;/SPAN&gt;&lt;A href="http://sampleserver6.arcgisonline.com/arcgis/sdk/rest/fsaddattachment.html"&gt;addAttachment operation&lt;/A&gt;&lt;SPAN&gt;, but I don't think anything else changed.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Mon, 28 Jan 2013 20:30:21 GMT</pubDate>
    <dc:creator>ShreyasVakil</dc:creator>
    <dc:date>2013-01-28T20:30:21Z</dc:date>
    <item>
      <title>FeatureLayer.AddAttachment() does not work properly</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/featurelayer-addattachment-does-not-work-properly/m-p/393756#M36324</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Hello,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I am currently working on a mobile solution using JQuery Mobile and ArcGIS JavaScript API. I have been developing my own attribute editor as the default ESRI attribute and attachment editor widgets do not match to our style guides. Everything is working so far apart from the attachment handling. &lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I have been trying adding attachments (mainly images) using the following piece of code:&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;PRE class="plain" name="code"&gt;if (featureayer.isEditable &amp;amp;&amp;amp; featureayer.hasAttachments) { &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; featureayer.addAttachment(selectedFeatureObjectID, document.getElementById("addImageForm"), function (result) { &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; ... &amp;nbsp;&amp;nbsp;&amp;nbsp; }, &amp;nbsp;&amp;nbsp;&amp;nbsp; function (error) { &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; ... &amp;nbsp;&amp;nbsp;&amp;nbsp; });&lt;/PRE&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;My application is trying to post the selected image to my local server and I can see the following post request payload using the Chrome developer tools:&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;------WebKitFormBoundaryqLUYc2Wu8g9s28A1&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Content-Disposition: form-data; name="inputFile"; filename="images.jpeg"&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Content-Type: image/jpeg&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;------WebKitFormBoundaryqLUYc2Wu8g9s28A1&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Content-Disposition: form-data; name="token"&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;B8rm1jrQR_Vh0VMZQ1EJ17IXpM284A3C3VmJHvoQC5w19hU5UwuU5TKseEAZTWP8NgaOOjV_4kJRJajyfKtCRw..&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;------WebKitFormBoundaryqLUYc2Wu8g9s28A1&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Content-Disposition: form-data; name="f"&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;json&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;------WebKitFormBoundaryqLUYc2Wu8g9s28A1--&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;However it is always getting back with an error message:&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Error: Error performing add attachment operation&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Code: 500&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Unfortunately, I have no idea what might be the reason of this problem. I can add attachments using ArcGIS Desktop and the ArcGIS Server Rest API via Browser so that I am assuming that this is not a issue with my feature service.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Thank you very much for any hint! Best regards&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Thomas&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 14 Nov 2012 14:31:13 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/featurelayer-addattachment-does-not-work-properly/m-p/393756#M36324</guid>
      <dc:creator>ThomasLaue</dc:creator>
      <dc:date>2012-11-14T14:31:13Z</dc:date>
    </item>
    <item>
      <title>Re: FeatureLayer.AddAttachment() does not work properly</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/featurelayer-addattachment-does-not-work-properly/m-p/393757#M36325</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Check out this code sample which demonstrates adding attachments.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;PRE class="plain" name="code"&gt;&amp;lt;!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"&amp;gt; &amp;lt;html&amp;gt; &amp;nbsp; &amp;lt;head&amp;gt; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;meta http-equiv="Content-Type" content="text/html; charset=utf-8"/&amp;gt; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;meta http-equiv="X-UA-Compatible" content="IE=7,IE=9" /&amp;gt; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;!--The viewport meta tag is used to improve the presentation and behavior of the samples &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; on iOS devices--&amp;gt; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;meta name="viewport" content="initial-scale=0.5, maximum-scale=1,user-scalable=no"/&amp;gt; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;title&amp;gt;Test Add Attachment&amp;lt;/title&amp;gt; &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;link rel="stylesheet" type="text/css" href="http://serverapi.arcgisonline.com/jsapi/arcgis/3.1/js/dojo/dijit/themes/claro/claro.css"&amp;gt; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;!--&amp;lt;script type="text/javascript" src="https://getfirebug.com/firebug-lite.js"&amp;gt;&amp;lt;/script&amp;gt;--&amp;gt;&amp;nbsp; &amp;lt;script type="text/javascript"&amp;gt; &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; var djConfig = { &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; parseOnLoad: true &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; }; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;/script&amp;gt; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;script type="text/javascript" src="http://serverapi.arcgisonline.com/jsapi/arcgis/?v=3.1"&amp;gt;&amp;lt;/script&amp;gt; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;script type="text/javascript"&amp;gt; &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; dojo.require("esri.map"); &amp;nbsp;&amp;nbsp; dojo.require("esri.layers.FeatureLayer"); &amp;nbsp;&amp;nbsp; dojo.require("dijit.form.TextBox"); &amp;nbsp;&amp;nbsp; dojo.require("dijit.form.DateTextBox"); &amp;nbsp;&amp;nbsp; dojo.require("dijit.form.TimeTextBox"); &amp;nbsp;&amp;nbsp; dojo.require("dijit.form.MultiSelect"); &amp;nbsp;&amp;nbsp; dojo.require("dijit.ProgressBar"); &amp;nbsp;&amp;nbsp; dojo.require("dojo.parser"); &amp;nbsp;&amp;nbsp; dojo.require("dojo.data.ItemFileReadStore"); &amp;nbsp;&amp;nbsp; dojo.require("dijit.form.ComboBox");&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp; var featureLayer, map,&amp;nbsp; maxExtent,customExtentAndSR, tiledMapServiceLayer; &amp;nbsp;&amp;nbsp; //This function loads the map &amp;nbsp;&amp;nbsp;&amp;nbsp; function init()&amp;nbsp;&amp;nbsp; { &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp; esri.config.defaults.io.proxyUrl = "http://svakil/JSProxyPage/proxy.ashx"; &amp;nbsp; esri.config.defaults.io.alwaysUseProxy = false; &amp;nbsp; customExtentAndSR = new esri.geometry.Extent(-14091875,5638085,-12763165,6396109, new esri.SpatialReference({"wkid":3857})); &amp;nbsp; map = new esri.Map("map"); &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp; dojo.connect(map, "onLoad", function() { &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; maxExtent = map.extent; &amp;nbsp;&amp;nbsp; &amp;nbsp; dojo.connect(map, "onClick", function(evt){ &amp;nbsp;&amp;nbsp;&amp;nbsp; console.log(evt); &amp;nbsp;&amp;nbsp;&amp;nbsp; map.graphics.clear(); &amp;nbsp;&amp;nbsp;&amp;nbsp; map.graphics.add(new esri.Graphic(evt.mapPoint,&amp;nbsp; new esri.symbol.SimpleMarkerSymbol(esri.symbol.SimpleMarkerSymbol.STYLE_CROSS, 25, &amp;nbsp;&amp;nbsp;&amp;nbsp; new esri.symbol.SimpleLineSymbol(esri.symbol.SimpleLineSymbol.STYLE_SOLID, &amp;nbsp;&amp;nbsp;&amp;nbsp; new dojo.Color([255,0,0]), 4)))); &amp;nbsp;&amp;nbsp;&amp;nbsp; submitForm(); &amp;nbsp;&amp;nbsp; }); &amp;nbsp; }); &amp;nbsp; var tiledMapServiceLayer = new esri.layers.ArcGISTiledMapServiceLayer("http://services.arcgisonline.com/ArcGIS/rest/services/World_Street_Map/MapServer"); &amp;nbsp; var featureServiceURL = "http://sampleserver3.arcgisonline.com/ArcGIS/rest/services/SanFrancisco/311Incidents/FeatureServer/0"; &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp; featureLayer = new esri.layers.FeatureLayer(featureServiceURL, { &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; outFields: ["*"], &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; visible: false &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; }); &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp; map.addLayers([tiledMapServiceLayer, featureLayer]); &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; } &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; function submitForm() { &amp;nbsp; featureLayer.addAttachment(5176728, document.getElementById("myForm6") ,callback , function(err){console.log(err);});&amp;nbsp; } &amp;nbsp;&amp;nbsp;&amp;nbsp; function callback(result){ &amp;nbsp; console.log(result);&amp;nbsp; }&amp;nbsp; dojo.addOnLoad(init);&amp;nbsp; &amp;lt;/script&amp;gt; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;body class="claro"&amp;gt;&amp;nbsp; &amp;lt;div id="map" style="position:relative; width:600px; height:400px; border:1px solid #000; margin:0px auto;"&amp;gt;&amp;lt;/div&amp;gt; &amp;nbsp; &amp;lt;form id="myForm6"&amp;gt;&amp;lt;input type="file" name="attachment"/&amp;gt;&amp;lt;/form&amp;gt; &amp;lt;/body&amp;gt; &amp;lt;/html&amp;gt;&amp;nbsp; &amp;nbsp; &lt;/PRE&gt;&lt;DIV style="display:none;"&gt; &lt;/DIV&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;In order to successfully add an attachment the formNode form must contain an input item with a 'name' attribute set to the term "attachment". Below is the bare bones HTML Form which allows for successful attachments. If the name element is not tagged with the input the application with throw a "processing error" with error code 500 in firebug.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp; &amp;lt;form id="myForm1"&amp;gt;&amp;lt;input type="file" name="attachment"/&amp;gt;&amp;lt;/form&amp;gt;&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Let me know if it works.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Thanks,&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Shreyas&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 14 Nov 2012 19:36:16 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/featurelayer-addattachment-does-not-work-properly/m-p/393757#M36325</guid>
      <dc:creator>ShreyasVakil</dc:creator>
      <dc:date>2012-11-14T19:36:16Z</dc:date>
    </item>
    <item>
      <title>Re: FeatureLayer.AddAttachment() does not work properly</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/featurelayer-addattachment-does-not-work-properly/m-p/393758#M36326</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Thank you very much for you help. It is working correctly now. Maybe this piece of information could be added to the official documentation. It would have saved me some hours if I had learned this requirement before.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 15 Nov 2012 06:37:14 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/featurelayer-addattachment-does-not-work-properly/m-p/393758#M36326</guid>
      <dc:creator>ThomasLaue</dc:creator>
      <dc:date>2012-11-15T06:37:14Z</dc:date>
    </item>
    <item>
      <title>Re: FeatureLayer.AddAttachment() does not work properly</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/featurelayer-addattachment-does-not-work-properly/m-p/393759#M36327</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;I apologize for that and I understand how frustrating it can be. But we are working on the documentation to make it more robust and helpful.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Just to make life of other developers easy who are going through the same trouble, can you please mark the previous post as the answer? It would be helpful to others.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 15 Nov 2012 15:28:20 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/featurelayer-addattachment-does-not-work-properly/m-p/393759#M36327</guid>
      <dc:creator>ShreyasVakil</dc:creator>
      <dc:date>2012-11-15T15:28:20Z</dc:date>
    </item>
    <item>
      <title>Re: FeatureLayer.AddAttachment() does not work properly</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/featurelayer-addattachment-does-not-work-properly/m-p/393760#M36328</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Hello, I am having a simliar issue described above and I used your steps which has gotten me to this point, but now I am stuck.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Is this issue with my proxy.jsp ? At this point, I do not know what this could be other than I just cannot post with this proxy.jsp.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Any feedback will probably be helpful and much appreciated.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Here is my code to add attachments:&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;&lt;SPAN&gt;esri.config.defaults.io.proxyUrl = "&lt;/SPAN&gt;&lt;A class="jive-link-external-small" href="http://domain.com/proxy/proxy.jsp" rel="nofollow" target="_blank"&gt;http://domain.com/proxy/proxy.jsp&lt;/A&gt;&lt;SPAN&gt;";&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; esri.config.defaults.io.alwaysUseProxy = false;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; featureLayer = new esri.layers.FeatureLayer(featureServiceUrl, {&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; outFields: ["*"],&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; visible: false&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; });&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; featureLayer.addAttachment(objectId, document.getElementById("photoForm"), attachmentSuccess, attachmentError);&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Here is the response that I receive:&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Request URL:&lt;/SPAN&gt;&lt;A href="http://domain.com/proxy/proxy.jsp?http://gis.magnolia-river.com/arcgis/rest/services/GasDev/FeatureServer/0/41612/addAttachment"&gt;http://domain.com/proxy/proxy.jsp?http://gis.magnolia-river.com/arcgis/rest/services/GasDev/FeatureServer/0/41612/addAttachment&lt;/A&gt;&lt;BR /&gt;&lt;SPAN&gt;Request Method:POST&lt;/SPAN&gt;&lt;BR /&gt;&lt;STRONG&gt;Status Code:405 Method Not Allowed&lt;/STRONG&gt;&lt;BR /&gt;&lt;SPAN&gt;Request Headersview source&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Content-Type:multipart/form-data; boundary=----WebKitFormBoundaryvZ097dQtmN9qqhNX&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Origin:file://&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;User-Agent:Mozilla/5.0 (iPhone; CPU iPhone OS 5_0 like Mac OS X) AppleWebKit/534.46 (KHTML, like Gecko) Version/5.1 Mobile/9A334 Safari/7534.48.3&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;X-Requested-With:XMLHttpRequest&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Query String Parametersview URL encoded&lt;/SPAN&gt;&lt;BR /&gt;&lt;A href="http://domain.com/arcgis/rest/services/GasDev/FeatureServer/0/41612/addAttachment:"&gt;http://domain.com/arcgis/rest/services/GasDev/FeatureServer/0/41612/addAttachment:&lt;/A&gt;&lt;BR /&gt;&lt;SPAN&gt;Request Payload&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;------WebKitFormBoundaryvZ097dQtmN9qqhNX&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Content-Disposition: form-data; name="attachment"; filename="Chrysanthemum.jpg"&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Content-Type: image/jpeg&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;------WebKitFormBoundaryvZ097dQtmN9qqhNX&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Content-Disposition: form-data; name="f"&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;json&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;------WebKitFormBoundaryvZ097dQtmN9qqhNX--&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Response Headersview source&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Allow:GET, HEAD, OPTIONS, TRACE&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Content-Length:1293&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Content-Type:text/html&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Date:Mon, 28 Jan 2013 14:05:58 GMT&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Server:Microsoft-IIS/7.5&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;X-Powered-By:ASP.NET&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 28 Jan 2013 12:11:02 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/featurelayer-addattachment-does-not-work-properly/m-p/393760#M36328</guid>
      <dc:creator>JosephHarris1</dc:creator>
      <dc:date>2013-01-28T12:11:02Z</dc:date>
    </item>
    <item>
      <title>Re: FeatureLayer.AddAttachment() does not work properly</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/featurelayer-addattachment-does-not-work-properly/m-p/393761#M36329</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;I tested your &lt;/SPAN&gt;&lt;A href="http://gis.magnolia-river.com/arcgis/rest/services/GasDev/FeatureServer/0"&gt;service&lt;/A&gt;&lt;SPAN&gt; against the same above code and it works fine. I was able to add an attachment. This makes me believe that there might be something wrong with the proxy page.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Can you test your proxy page from the browser?&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Just call the following URL in your browser and see if it takes you to your REST endpoint:&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;&lt;A class="jive-link-external-small" href="http://" rel="nofollow" target="_blank"&gt;http://&lt;/A&gt;&lt;SPAN&gt;&amp;lt;yourdomain&amp;gt;/&amp;lt;proxyFolderIfAny&amp;gt;/proxy.jsp?&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;A href="http://gis.magnolia-river.com/arcgis/rest/services/GasDev/FeatureServer/0/41612"&gt;http://gis.magnolia-river.com/arcgis/rest/services/GasDev/FeatureServer/0/41612&lt;/A&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Here is the &lt;/SPAN&gt;&lt;A href="http://help.arcgis.com/en/webapi/javascript/arcgis/jshelp/#ags_proxy"&gt;documentation &lt;/A&gt;&lt;SPAN&gt;for setting the proxy page.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 28 Jan 2013 14:31:51 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/featurelayer-addattachment-does-not-work-properly/m-p/393761#M36329</guid>
      <dc:creator>ShreyasVakil</dc:creator>
      <dc:date>2013-01-28T14:31:51Z</dc:date>
    </item>
    <item>
      <title>Re: FeatureLayer.AddAttachment() does not work properly</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/featurelayer-addattachment-does-not-work-properly/m-p/393762#M36330</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Hi Shreyas,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Are you aware of any change in attachment option in 10.1, the reason I am asking this is as follows:&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; I am trying to upload a image from iOS 5 device to ArcGIS Feature service with help of picup (&lt;/SPAN&gt;&lt;A href="http://picupapp.com/"&gt;http://picupapp.com/&lt;/A&gt;&lt;SPAN&gt;).&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;With ArcGIS Server 10, I am able to add attachment however, when I point to same service published on ArcGIS Server 10.1 it does not work.&amp;nbsp; &lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I am attaching the http request captured from wireshark for your reference. I do not see any difference between them but if you have any inputs some direction to solve this please share it with me.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;[ATTACH=CONFIG]21133[/ATTACH]&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;[ATTACH=CONFIG]21134[/ATTACH]&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Thanks,&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Rahul&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 28 Jan 2013 15:30:36 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/featurelayer-addattachment-does-not-work-properly/m-p/393762#M36330</guid>
      <dc:creator>RahulMetangale1</dc:creator>
      <dc:date>2013-01-28T15:30:36Z</dc:date>
    </item>
    <item>
      <title>Re: FeatureLayer.AddAttachment() does not work properly</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/featurelayer-addattachment-does-not-work-properly/m-p/393763#M36331</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;BLOCKQUOTE class="jive-quote"&gt;I tested your &lt;A href="http://gis.magnolia-river.com/arcgis/rest/services/GasDev/FeatureServer/0"&gt;service&lt;/A&gt; against the same above code and it works fine. I was able to add an attachment. This makes me believe that there might be something wrong with the proxy page.&lt;BR /&gt;&lt;BR /&gt;Can you test your proxy page from the browser?&lt;BR /&gt;&lt;BR /&gt;Just call the following URL in your browser and see if it takes you to your REST endpoint:&lt;BR /&gt;&lt;BR /&gt;http://&amp;lt;yourdomain&amp;gt;/&amp;lt;proxyFolderIfAny&amp;gt;/proxy.jsp?&lt;A href="http://gis.magnolia-river.com/arcgis/rest/services/GasDev/FeatureServer/0/41612"&gt;http://gis.magnolia-river.com/arcgis/rest/services/GasDev/FeatureServer/0/41612&lt;/A&gt;&lt;BR /&gt;&lt;BR /&gt;Here is the &lt;A href="http://help.arcgis.com/en/webapi/javascript/arcgis/jshelp/#ags_proxy"&gt;documentation &lt;/A&gt;for setting the proxy page.&lt;/BLOCKQUOTE&gt;&lt;BR /&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Ok, I got it to work with the 3.0 ArcGIS javascript leveraging CORS, no proxy needed.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;A side question would be, can I upload photos from a directory, versus a file being selected through the &amp;lt;input type="file"&amp;gt;&amp;nbsp; ??&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;If this was a mobile app and I took pictures, could I upload them with this same approach without using &amp;lt;input type="file"&amp;gt; ?&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Thanks for your help on the first part.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 28 Jan 2013 18:04:59 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/featurelayer-addattachment-does-not-work-properly/m-p/393763#M36331</guid>
      <dc:creator>JosephHarris1</dc:creator>
      <dc:date>2013-01-28T18:04:59Z</dc:date>
    </item>
    <item>
      <title>Re: FeatureLayer.AddAttachment() does not work properly</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/featurelayer-addattachment-does-not-work-properly/m-p/393764#M36332</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;BLOCKQUOTE class="jive-quote"&gt;Ok, I got it to work with the 3.0 ArcGIS javascript leveraging CORS, no proxy needed.&lt;/BLOCKQUOTE&gt;&lt;BR /&gt;&lt;SPAN&gt;I am glad you got it to work!!&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BLOCKQUOTE class="jive-quote"&gt;A side question would be, can I upload photos from a directory, versus a file being selected through the &amp;lt;input type="file"&amp;gt;&amp;nbsp; ??&lt;/BLOCKQUOTE&gt;&lt;BR /&gt;&lt;SPAN&gt;I may be wrong on this, but I don't think there is an easy way to upload a folder using just HTML/Javascript. Here are just a few links which discusses them.&lt;/SPAN&gt;&lt;BR /&gt;&lt;A href="http://stackoverflow.com/questions/254251/what-is-the-best-way-to-upload-a-folder-to-a-website"&gt;Link 1&lt;/A&gt;&lt;BR /&gt;&lt;A href="http://stackoverflow.com/questions/159600/what-is-the-best-client-side-browser-library-to-upload-multiple-files-over-http"&gt;Link 2&lt;/A&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BLOCKQUOTE class="jive-quote"&gt;If this was a mobile app and I took pictures, could I upload them with this same approach without using &amp;lt;input type="file"&amp;gt; ?&lt;/BLOCKQUOTE&gt;&lt;BR /&gt;&lt;SPAN&gt;I tested the add attachment sample on a Android Tablet's browser and it worked fine. So I think it should work.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 28 Jan 2013 20:21:19 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/featurelayer-addattachment-does-not-work-properly/m-p/393764#M36332</guid>
      <dc:creator>ShreyasVakil</dc:creator>
      <dc:date>2013-01-28T20:21:19Z</dc:date>
    </item>
    <item>
      <title>Re: FeatureLayer.AddAttachment() does not work properly</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/featurelayer-addattachment-does-not-work-properly/m-p/393765#M36333</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;BLOCKQUOTE class="jive-quote"&gt;Hi Shreyas,&lt;BR /&gt;&lt;BR /&gt;Are you aware of any change in attachment option in 10.1, the reason I am asking this is as follows:&lt;BR /&gt; I am trying to upload a image from iOS 5 device to ArcGIS Feature service with help of picup (&lt;A href="http://picupapp.com/"&gt;http://picupapp.com/&lt;/A&gt;).&lt;BR /&gt;With ArcGIS Server 10, I am able to add attachment however, when I point to same service published on ArcGIS Server 10.1 it does not work.&amp;nbsp; &lt;BR /&gt;&lt;BR /&gt;I am attaching the http request captured from wireshark for your reference. I do not see any difference between them but if you have any inputs some direction to solve this please share it with me.&lt;BR /&gt;&lt;BR /&gt;[ATTACH=CONFIG]21133[/ATTACH]&lt;BR /&gt;[ATTACH=CONFIG]21134[/ATTACH]&lt;BR /&gt;&lt;BR /&gt;Thanks,&lt;BR /&gt;Rahul&lt;/BLOCKQUOTE&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I never worked on &lt;/SPAN&gt;&lt;A href="http://picupapp.com/"&gt;http://picupapp.com/&lt;/A&gt;&lt;SPAN&gt; ,so I cannot really comment on this one. &lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;There was a new parameter added called as gdbVersion at 10.1 for &lt;/SPAN&gt;&lt;A href="http://sampleserver6.arcgisonline.com/arcgis/sdk/rest/fsaddattachment.html"&gt;addAttachment operation&lt;/A&gt;&lt;SPAN&gt;, but I don't think anything else changed.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 28 Jan 2013 20:30:21 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/featurelayer-addattachment-does-not-work-properly/m-p/393765#M36333</guid>
      <dc:creator>ShreyasVakil</dc:creator>
      <dc:date>2013-01-28T20:30:21Z</dc:date>
    </item>
    <item>
      <title>Re: FeatureLayer.AddAttachment() does not work properly</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/featurelayer-addattachment-does-not-work-properly/m-p/393766#M36334</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I am thankful that I found this post.&amp;nbsp; I too was struggling getting this to work in my app.&amp;nbsp; I agree very much with you about adding this information to the documentation. I see this post is 2 years old and it still hasn't been added to the documentation.&amp;nbsp; Upon finding this post I had my app working in a couple of minutes!&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 19 Nov 2014 21:39:25 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/featurelayer-addattachment-does-not-work-properly/m-p/393766#M36334</guid>
      <dc:creator>TomSellsted</dc:creator>
      <dc:date>2014-11-19T21:39:25Z</dc:date>
    </item>
  </channel>
</rss>

