2

I was just wondering if anyone has used the imageshack api as i am trying to use it and i am having some issues as it just fails and will no upload my image.

the php library for image shack can be found here http://elliottback.com/wp/using-the-imageshack-xml-api/

i pass the for file element to the upload function but it just does not want to do it. does anyone have any ideas or any links with useful help? Cheers Mark

Charles
  • 50,943
  • 13
  • 104
  • 142
markblue777
  • 829
  • 3
  • 13
  • 28

2 Answers2

1

It is fine it was a silly mistake i was making and sending the wrong information to the class

i was doing $_FILES['file']['name']

instead of the correct way which was

$_FILES['file']['tmp_name']

after i change that it was fine

markblue777
  • 829
  • 3
  • 13
  • 28
0

According to the API class code, the line 15:

curl_setopt($ch, CURLOPT_TIMEOUT, 240);

sets a maximum execution time for the cURL functions of 240 seconds (4 minutes).

That could be the possible error. Try setting that value to 600 seconds (10 minutes) and try again.

Also, the time needed to upload the file depends on the file size and on your internet's upload speed.

Also, showing us the code that you are using (besides that class) would be a HUGE help.

Pedro Cunha
  • 164
  • 1
  • 1
  • 9