Jun 06
Saving CFHTTP file content
Posted by James Netherton | Wednesday 06 June 2007 8:06 AM | In ColdFusion
I really should study the ColdFusion documentation more closely….
I never knew you could save the contents returned from CFHTTP to a specified file without having to use CFFILE as there are file and path attributes. Observe…
<cfhttp url="http://www.google.co.uk/intl/en_uk/images/logo.gif" file="googleLogo.gif" path="#expandPath('.')#"/>
2 Comments
[Post comment]
1
Posted by charlie arehart | Saturday 28 July 10:07 AM
Very nice, James. You know, I’d never noticed that one myself, and I just checked the tag history and see that the attribute was there going back to at least CF4. Hope I can remember it.
BTW, I just found your blog today for the first time, and you have a lot of nice posts. Thanks for the effort.
One thing, though: you may want to consider making your comment captcha easier. I’ve written on how easy that is to do: http://carehart.org/blog/client/index.cfm/2006/10/7/lyla_captcha_simplified_xml_file
2
Posted by James Netherton | Sunday 29 July 5:07 AM
Charlie, thanks for the captcha tip! I made the suggested changes to the XML file