Viewing 4 replies - 1 through 4 (of 4 total)
  • Hmm, that’s odd. Have you checked the errors by enabling the debug mode?

    Also, check what your STW console says, as many of the “Data from STW was empty” errors have been due to an issue that gets reported in your STW account.

    When I checked my account for that issue, I hadn’t locked associated my website with the permitted websites in the security settings on STW. You need to give your website permission in STW to prevent other people from using your access credentials.

    See here:
    http://support.shrinktheweb.com/Knowledgebase/Article/View/7/1/how-do-i-lock-my-account–update-allowed-referrers

    @dan Harrison,

    I had the same problem, but I have solved it. I took a peek at another plugin (Webphysiology) and look what was different, because that one was working without a problem. Maybe it worth to update your plugin with the following code.

    This curl request is working in the thumbnailer.inc.php:

    $ch = curl_init();
    curl_setopt($ch, CURLOPT_URL, $request_url);
    curl_setopt($ch, CURLOPT_RETURNTRANSFER,1); // forces response into return string, not echo
    curl_setopt($ch, CURLOPT_HEADER, 0);
    curl_setopt($ch, CURLOPT_HTTPHEADER, Array("User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.8.1.15) Gecko/20080623 Firefox/2.0.0.15") );
    $remotedata = curl_exec($ch);
    curl_close($ch);

    Again, @jvandemerwe – comparing this to the existing code, I find it odd that forging the user agent solves the issue.

    I see that you’ve also removed:
    curl_setopt($ch, CURLOPT_FOLLOWLOCATION, 1);

    Happy to make this a fix, but I want to make sure it’s a fix and not just a coincidence.

    Dan

    I am not a great expert in CURL, but until now the modification works on all the browsers I tested.

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘Data from STW was empty.’ is closed to new replies.