I think there is a function in the facebook graph API that you can use:
http://facebookgraph.riaforge.org/


> Howdy folks,
> 
> I'm working on a ColdFusion application that creates events in 
> Facebook.  I have no trouble authenticating users and creating simple 
> events, but as soon as I add a picture with CFHTTPPARAM, I get a blank 
> response from Facebook.
> 
> Here's the code I have that works:
> 
> -----
> 
> <cfset params = 'access_token=#client.
> access_token#&event_info={"page_id": "#uid#", "start_time": 
> "1295578547", "name": "Test Event", "location": "Test","privacy": 
> "OPEN","description": "Test Event"}'>
>               
> <cfhttp url="https://api.facebook.com/method/events.create?#params#"; 
> method="get"></cfhttp>
> 
> -----
> 
> Given the correct permissions and authentication, this works great.  
> But as soon as I change my CFHTTP statement, the code fails.  This is 
> the code I'm using:
> 
> -----
> 
> <cfhttp url="https://api.facebook.com/method/events.create?#params#"; 
> method="post" multipart="yes">
    
> <cfhttpparam file="E:\test\sampleimage.jpg" type="file" name="image.
> jpg" mimetype="image/jpeg">
> </cfhttp>
> 
> -----
> 
> Anyone have any ideas?  It might be that Facebook is looking for some 
> kind of a header, but I'm not sure what that would be.
> 
> Thanks in advance!
> David Six 


~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Order the Adobe Coldfusion Anthology now!
http://www.amazon.com/Adobe-Coldfusion-Anthology-Michael-Dinowitz/dp/1430272155/?tag=houseoffusion
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:338059
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm

Reply via email to