Changeset 21291 for extensions


Ignore:
Timestamp:
Mar 6, 2013, 5:55:12 PM (12 years ago)
Author:
mistic100
Message:

safe_mode

File:
1 edited

Legend:

Unmodified
Added
Removed
  • extensions/pbase2piwigo/include/functions.inc.php

    r19832 r21291  
    349349      curl_setopt($ch, CURLOPT_HTTPHEADER, array("Accept-language: en"));
    350350      curl_setopt($ch, CURLOPT_USERAGENT, 'Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 5.1)');
    351       curl_setopt($ch, CURLOPT_FOLLOWLOCATION, true);
    352       curl_setopt($ch, CURLOPT_MAXREDIRS, 1);
     351      curl_setopt($ch, CURLOPT_TIMEOUT, 30);
     352      if (!ini_get('safe_mode'))
     353      {
     354        curl_setopt($ch, CURLOPT_FOLLOWLOCATION, true);
     355        curl_setopt($ch, CURLOPT_MAXREDIRS, 1);
     356      }
    353357      if (strpos($src, 'https://') !== false)
    354358      {
Note: See TracChangeset for help on using the changeset viewer.