4

I have a JavaScript function to post image with Graph API.

function postOpenGraphFromUrl(imageUrl, pageUrl, callback) {
  var options = {
    'photo' : pageUrl,
    'image[0][url]' : imageUrl,
    'image[0][user_generated]' : true
  };

  FB.api('/me/hairchalk:create', 'post', options, function(response) {
    if (callback && typeof callback == 'function') {
      callback(response);
    }
  });
}

When I try to execute I have this error in response:

/**/ FB.__globalCallbacks.f4c69a98({"error":{"type":"Exception","message":"The user generated photo at https:\/\/hairchalk.ltst.su\/uploads\/look\/file\/7\/large_photo.jpg could not be uploaded because: cURL Error [#60, CURLE_SSL_CACERT]: Transfer failed.","code":1611180}});

As I can see from the error message there is kind of problem with curl, but on my side I don't use curl at all. How can I solve this problem?

jastkand
  • 131
  • 2
  • 6
  • 1
    As I understood the problem was in site's ssl certificate. I forgot to add chain certificate to it. – jastkand Jun 25 '14 at 09:46

1 Answers1

0

Adding the chain certification fixed this for me. Here's some instructions: http://www.entrust.net/knowledge-base/technote.cfm?tn=8166

mferro
  • 9
  • 1