I'm using php to post an image along with some other data.
Using the sample code from the php doc site (example 2 here: http://php.net/manual/en/function.curl-setopt.php, if I output what gets sent with my script ($_FILE) I see something like this:
Array
(
[file] => Array
(
[name] => temp.gif
[type] => application/octet-stream
[tmp_name] => /tmp/phpO1cgxW
[error] => 0
[size] => 3386
)
)
My code for creating the post data is:
$postData = array('sphotos'=>'', 'title'=>urlencode($title), 'description'=>urlencode($description), 'tags'=>$tags, 'category'=>$category, 'gallery'=>'',
'file'=>'@/web/sites/flickr/temp.gif');
I've verified that the file is, in fact, a gif file using the 'file' command in linux.
I just can't get it to show up as a gif type.
Any ideas?
G-Man