Posterous API issue
Hello,
I am trying make a post to my posterous blog from within my iPhone app with the following code but I always got 404 error.
Yet to mention, when I try this url method in browser it works perfectly fine there.
Check my code here: http://pastie.org/981549
Can anyone help me in cracking this issue out!
2 Answers
-
Accepted Answer
Try this
xhr.open('POST','http://somepage.com'); xhr.setRequestHeader('Authorization','Basic'+Ti.Utils.base64encode(username+':'+password)); xhr.send({title:'check me out',media:image});
-
@Daniel Thanks for the help, It works perfectly fine now.