|
|
|||||||||
|
|||||||||
| |||||||||
|
|
|
| |||||||||
![]() |
|
|
«
Previous Thread
|
Next Thread
»
|
Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
|
|
Get inside! Sample the range of functionality easily built with JMSL Library for Time Series Data Analysis, Heat Maps, Portfolio Optimization, Monte Carlo Simulation, Stock Price Charting and more. Download Now! |
|
#1
|
|||
|
|||
|
Hi,
My question to anyone is did MM update this function in MX or left it alone? I am using the CF5 Developer Server for development and the function works but all of what I read mentions it as a new function in MX. Also: I am attempting to use the function and can not get the content string back but I get a content_length of the data that I sent to the cfm file. My code is: <cfset x = GetHttpRequestData()> <cfset xdata =""> <cfloop collection = #x.headers# item = "http_item"> <cfset xdata = "#xdata#<record item='#xmlformat(http_item)#' value='#xmlformat(StructFind(x.headers, http_item))#' />"> </cfloop> <cfoutput><cfcontent type="text/xml"><?xml version='1.0'?><some>#xdata#<content value='#x.content#' /><method value='#x.method#' /></some></cfoutput> The response I get is always: <?xml version='1.0'?><some><record item="CACHE_CONTROL" value="no-cache" /><record item="CONTENT_LENGTH" value="71" /><record item="CONTENT_TYPE" value="application/x-www-form-urlencoded" /><record item="COOKIE" value="CFID=1; CFTOKEN=26067650" /><record item="HOST" value="127.0.0.1" /><record item="USER_AGENT" value="Shockwave Flash" /><content value="" /><method value="GET" /></some> Before you suggest that I upgrade to MX for CF or Flash, I am a student and can't afford the 1500 to upgrade. But I am just wondering why I would be getting all of this info back with a content_length of 71 but no content. Can I not access the content? Alex Student, Montgomery College Rockville MD |
|
#2
|
|||
|
|||
|
From...
http://livedocs.macromedia.com/cold...s94.htm#1955092[/url] content Raw content from the form submitted by the client, in string or binary format. For content to be considered string data, the FORM request header "CONTENT_TYPE" must start with "text/" or be special case "application/x-www-form-urlencoded". Other types are stored as a binary object. I'm not 100% sure on this one, but it makes reference to the content being retrieved via a form (presumably the POST method)but your method is actually GET. Can you try your script by invoking it via POST? |
![]() |
| Viewing: Dev Shed Forums > Programming Languages - More > ColdFusion Development > Please help student with CFHTTPRequest in CF5 |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|
|
|