coldfusion - CFHTTP issue connecting to XML file -


i have following xml, contained in file named inventory4zeroone.xml:

<?xml version="1.0" encoding="utf-8"?> <flexquery>   <queryname>ecommerce inventory</queryname>   <data>     <item>       <web>1</web>       <productid>8203291034586124284</productid>       <item_sid></item_sid>       <categoryid>mc</categoryid>       <title>swoosh rnd frt hood white lrg</title>       <description>great product</description>       <price>34.5</price>       <qty>17</qty>       <image>8203291034586124284.jpg</image>       <thumb>8203291034586124284_t.jpg</thumb>       <active>1</active>       <updateddate>3/18/2013 11:31:41 am</updateddate>     </item>     <item>       <web>1</web>       <productid>8203291034586124285</productid>       <item_sid></item_sid>       <categoryid>mc</categoryid>       <title>acme rnd frt hood white lrg</title>       <description>great product</description>       <price>49.2</price>       <qty>19</qty>       <image>8603291034586124284.jpg</image>       <thumb>8603291034586124284_t.jpg</thumb>       <active>1</active>       <updateddate>3/18/2013 11:31:41 am</updateddate>     </item>   </data> </flexquery> 

i can browse directly @ http://www.scrapbookcentral.co.nz/xml/inventory4zeroone.xml.

however, when tried fetch file via cfhttp follows:

<cfhttp url="http://www.scrapbookcentral.co.nz/xml/inventory4zeroone.xml"          method="get"          resolveurl="yes"> 

i following error:

enter image description here

you can view happening @ http://www.scrapbookcentral.co.nz/tasks/rpimportinventory.cfm

i found site solution "unable determine mime type of file" part of error, changed call to:

<cfhttp url="http://www.scrapbookcentral.co.nz/xml/inventory4zeroone.xml"          method="get"          resolveurl="yes">     <cfhttpparam type="header" name="mimetype" value="application/xml" /> </cfhttp> 

that didn't work. same error occurs.

so, read other sites saying might firewall issue. however, our systems admin says there no firewall issues access these files.

so, i'm @ loss , appreciate assistance.

it must network.

try running code here http://cflive.net/ - works fine.

i've run this:

<cfhttp url="http://www.scrapbookcentral.co.nz/xml/inventory4zeroone.xml" method="get" result="myresult"> <cfhttpparam type="header" name="mimetype" value="application/xml" /> </cfhttp> <cfdump var="#myresult#"> 

and worked fine. i'd drop resolveurl bit , maybe add useragent servers set not allow connections non-browsers.


Comments

Popular posts from this blog

html - How to style widget with post count different than without post count -

How to remove text and logo OR add Overflow on Android ActionBar using AppCompat on API 8? -

javascript - storing input from prompt in array and displaying the array -