WordPress.org

Plugin Directory

Changeset 827644


Ignore:
Timestamp:
12/23/13 20:19:02 (4 years ago)
Author:
UnderWordPressure
Message:

Preventive examination whether url_fopen is possible. If not you will got feedback.

Location:
faviroll/trunk
Files:
1 added
10 edited

Legend:

Unmodified
Added
Removed
  • faviroll/trunk/FavirollAdmin.class.php

    r824929 r827644  
    22/* 
    33 FavirollAdmin - Class for wordpress plugin "Faviroll" backend 
    4  Author: ANDURBAN.DE 
     4 Author: andurban.de 
    55 Version: latest 
    66 ---------------------------------------------------------------------------------------- 
     
    3030    function __construct() { 
    3131        parent::__construct(); 
     32 
    3233        $this->initOptions(); 
    3334        $this->initDefaultIcon(); 
     
    4344    /** 
    4445     * Init and load options from DB to member: opts. 
    45      */ 
     46     */  
    4647    function initOptions() { 
    4748 
     
    165166     * @return error message if cache directory is not writable, or the string is given into method 
    166167     */ 
    167     function getCachePermCheckMsg($passtru_message=null) { 
    168  
     168    function getPermCheckMsg($passtru_message=null) { 
     169 
     170        $result = ''; 
     171 
     172        if (!$this->can_url_fopen()) 
     173            $result.= '<p><strong style="color:#aa0000;background-color:#fff000;padding:0px 5px 0px 5px;">CAUTION:</strong> no permission to open external URLs.<br /> 
     174Faviroll works just properly if you (your webmaster) enable <strong>"allow_url_fopen"</strong> in php.ini.<br /> 
     175For further informations see: http://www.php.net/manual/en/configuration.changes.php 
     176</p>'; 
     177 
     178         
    169179        if (!$this->can_write_cache()) 
    170         return '<b>CAUTION</b>, no file permission to create icon-cache. 
    171 <p>You have to change the permissions.<br /> 
     180            $result.= '<p><strong style="color:#aa0000;background-color:#fff000;padding:0px 5px 0px 5px;">CAUTION:</strong> no file permission to create icon-cache.<br /> 
     181You have to change the permissions.<br /> 
    172182Use your ftp client, or the following command to fix it:<br /> 
    173183<br /> 
    174184<code># chmod 0775 '.$this->getCacheDir().'</code></p>'; 
    175185 
    176         return $passtru_message; 
     186        if (empty($result)) 
     187            return $passtru_message; 
     188     
     189        return $result;  
    177190    } 
    178191 
     
    212225 
    213226 
     227    /** 
     228     * Check url_fopen is possible, try to enable if not 
     229     * @return TRUE if url_fopen is possible 
     230     */ 
     231    function can_url_fopen() { 
     232     
     233        $inikey = 'allow_url_fopen'; 
     234     
     235        // Is usr_fopen allowed? 
     236        $isOk = ini_get($inikey); 
     237        if ($isOk) 
     238            return $isOk; 
     239     
     240        // Is it possible to enable url_fopen? 
     241        $opts = ini_get_all(); 
     242        if (isset($opt[$inikey]) && isset($opt[$inikey]['access'])) 
     243            $isOk = ($opt[$inikey]['access'] & INI_USER); 
     244     
     245        // set url_fopen 
     246        if ($isOk) 
     247            $isOk = ini_set($inikey,'1'); 
     248     
     249        return $isOk; 
     250         
     251    } 
     252     
     253     
    214254    /** 
    215255     * @return the factory default favicon URL 
     
    335375        } 
    336376 
    337         $message = $this->getCachePermCheckMsg($message); 
     377        $message = $this->getPermCheckMsg($message); 
    338378        if (!is_null($message)) 
    339379        $message = "<div class='updated fade below-h2' id='message'><p>$message</p></div>"; 
  • faviroll/trunk/FavirollWorker.class.php

    r824929 r827644  
    7474     
    7575    ################# 
    76     #               # 
     76  #               # 
    7777    #    GETTER     # 
    7878    #               # 
     
    239239 
    240240        $icourl = $this->locateIcon($rooturl); 
    241              
    242241        return $this->makeIcon($icourl,$basename); 
    243242    } 
     
    361360 
    362361        if (isset($codeURL)) { 
    363              
    364362            $link = parse_url($codeURL); 
    365363            extract($link,EXTR_PREFIX_ALL|EXTR_OVERWRITE|EXTR_REFS,'lk'); 
  • faviroll/trunk/faviroll-ajax.php

    r824929 r827644  
    4646function updateLinkImage($link_id,$newicon) { 
    4747    global $wpdb; 
    48     $result = "basename:"; 
     48    $result = 'basename:'; 
    4949 
    5050    $sqlcmd = "UPDATE $wpdb->links SET link_image = %s WHERE link_id = %s"; 
  • faviroll/trunk/faviroll.php

    r824929 r827644  
    55 Description: Caches all favicon.ico in PNG format and use this in your blogroll. 
    66 Author: andurban.de 
    7  Version:  0.5.2 
     7 Version:  0.5.2.1 
    88 Author URI:  http://www.andurban.de/ 
    99 Plugin URI:  http://www.andurban.de/tag/faviroll 
  • faviroll/trunk/php_thumb.functions.php

    r782888 r827644  
    1111class phpthumb_functions { 
    1212 
    13     function user_function_exists($functionname) { 
     13    public static function user_function_exists($functionname) { 
    1414        if (function_exists('get_defined_functions')) { 
    1515            static $get_defined_functions = array(); 
     
    2323 
    2424 
    25     function builtin_function_exists($functionname) { 
     25    public static function builtin_function_exists($functionname) { 
    2626        if (function_exists('get_defined_functions')) { 
    2727            static $get_defined_functions = array(); 
     
    3535 
    3636 
    37     function version_compare_replacement_sub($version1, $version2, $operator='') { 
     37    public static function version_compare_replacement_sub($version1, $version2, $operator='') { 
    3838        // If you specify the third optional operator argument, you can test for a particular relationship. 
    3939        // The possible operators are: <, lt, <=, le, >, gt, >=, ge, ==, =, eq, !=, <>, ne respectively. 
    40         // Using this argument, the function will return 1 if the relationship is the one specified by the operator, 0 otherwise. 
     40        // Using this argument, the public static function will return 1 if the relationship is the one specified by the operator, 0 otherwise. 
    4141 
    4242        // If a part contains special version strings these are handled in the following order: dev < (alpha = a) < (beta = b) < RC < pl 
     
    9595 
    9696 
    97     function version_compare_replacement($version1, $version2, $operator='') { 
     97    public static function version_compare_replacement($version1, $version2, $operator='') { 
    9898        if (function_exists('version_compare')) { 
    9999            // built into PHP v4.1.0+ 
     
    101101        } 
    102102 
    103         // The function first replaces _, - and + with a dot . in the version strings 
     103        // The public static function first replaces _, - and + with a dot . in the version strings 
    104104        $version1 = strtr($version1, '_-+', '...'); 
    105105        $version2 = strtr($version2, '_-+', '...'); 
     
    114114        $parts_count = max(count($parts1), count($parts2)); 
    115115        for ($i = 0; $i < $parts_count; $i++) { 
    116             $comparison = phpthumb_functions::version_compare_replacement_sub($version1, $version2, $operator); 
     116            $comparison = self::version_compare_replacement_sub($version1, $version2, $operator); 
    117117            if ($comparison != 0) { 
    118118                return $comparison; 
     
    123123 
    124124 
    125     function phpinfo_array() { 
     125    public static function phpinfo_array() { 
    126126        static $phpinfo_array = array(); 
    127127        if (empty($phpinfo_array)) { 
     
    136136 
    137137 
    138     function exif_info() { 
     138    public static function exif_info() { 
    139139        static $exif_info = array(); 
    140140        if (empty($exif_info)) { 
     
    147147                'Supported filetypes'    => '' 
    148148            ); 
    149             $phpinfo_array = phpthumb_functions::phpinfo_array(); 
     149            $phpinfo_array = self::phpinfo_array(); 
    150150            foreach ($phpinfo_array as $line) { 
    151151                $line = trim(strip_tags($line)); 
     
    162162 
    163163 
    164     function ImageTypeToMIMEtype($imagetype) { 
     164    public static function ImageTypeToMIMEtype($imagetype) { 
    165165        if (function_exists('image_type_to_mime_type') && ($imagetype >= 1) && ($imagetype <= 16)) { 
    166166            // PHP v4.3.0+ 
     
    197197 
    198198 
    199     function TranslateWHbyAngle($width, $height, $angle) { 
     199    public static function TranslateWHbyAngle($width, $height, $angle) { 
    200200        if (($angle % 180) == 0) { 
    201201            return array($width, $height); 
     
    206206    } 
    207207 
    208     function HexCharDisplay($string) { 
     208    public static function HexCharDisplay($string) { 
    209209        $len = strlen($string); 
    210210        $output = ''; 
     
    216216 
    217217 
    218     function IsHexColor($HexColorString) { 
     218    public static function IsHexColor($HexColorString) { 
    219219        return eregi('^[0-9A-F]{6}$', $HexColorString); 
    220220    } 
    221221 
    222222 
    223     function ImageColorAllocateAlphaSafe(&$gdimg_hexcolorallocate, $R, $G, $B, $alpha=false) { 
    224         if (phpthumb_functions::version_compare_replacement(phpversion(), '4.3.2', '>=') && ($alpha !== false)) { 
     223    public static function ImageColorAllocateAlphaSafe(&$gdimg_hexcolorallocate, $R, $G, $B, $alpha=false) { 
     224        if (self::version_compare_replacement(phpversion(), '4.3.2', '>=') && ($alpha !== false)) { 
    225225            return ImageColorAllocateAlpha($gdimg_hexcolorallocate, $R, $G, $B, intval($alpha)); 
    226226        } else { 
     
    229229    } 
    230230 
    231     function ImageHexColorAllocate(&$gdimg_hexcolorallocate, $HexColorString, $dieOnInvalid=false, $alpha=false) { 
     231    public static function ImageHexColorAllocate(&$gdimg_hexcolorallocate, $HexColorString, $dieOnInvalid=false, $alpha=false) { 
    232232        if (!is_resource($gdimg_hexcolorallocate)) { 
    233233            die('$gdimg_hexcolorallocate is not a GD resource in ImageHexColorAllocate()'); 
    234234        } 
    235         if (phpthumb_functions::IsHexColor($HexColorString)) { 
     235        if (self::IsHexColor($HexColorString)) { 
    236236            $R = hexdec(substr($HexColorString, 0, 2)); 
    237237            $G = hexdec(substr($HexColorString, 2, 2)); 
    238238            $B = hexdec(substr($HexColorString, 4, 2)); 
    239             return phpthumb_functions::ImageColorAllocateAlphaSafe($gdimg_hexcolorallocate, $R, $G, $B, $alpha); 
     239            return self::ImageColorAllocateAlphaSafe($gdimg_hexcolorallocate, $R, $G, $B, $alpha); 
    240240        } 
    241241        if ($dieOnInvalid) { 
     
    246246 
    247247 
    248     function HexColorXOR($hexcolor) { 
     248    public static function HexColorXOR($hexcolor) { 
    249249        return strtoupper(str_pad(dechex(~hexdec($hexcolor) & 0xFFFFFF), 6, '0', STR_PAD_LEFT)); 
    250250    } 
    251251 
    252252 
    253     function GetPixelColor(&$img, $x, $y) { 
     253    public static function GetPixelColor(&$img, $x, $y) { 
    254254        if (!is_resource($img)) { 
    255255            return false; 
     
    259259 
    260260 
    261     function PixelColorDifferencePercent($currentPixel, $targetPixel) { 
     261    public static function PixelColorDifferencePercent($currentPixel, $targetPixel) { 
    262262        $diff = 0; 
    263263        foreach ($targetPixel as $channel => $currentvalue) { 
     
    267267    } 
    268268 
    269     function GrayscaleValue($r, $g, $b) { 
     269    public static function GrayscaleValue($r, $g, $b) { 
    270270        return round(($r * 0.30) + ($g * 0.59) + ($b * 0.11)); 
    271271    } 
    272272 
    273273 
    274     function GrayscalePixel($OriginalPixel) { 
    275         $gray = phpthumb_functions::GrayscaleValue($OriginalPixel['red'], $OriginalPixel['green'], $OriginalPixel['blue']); 
     274    public static function GrayscalePixel($OriginalPixel) { 
     275        $gray = self::GrayscaleValue($OriginalPixel['red'], $OriginalPixel['green'], $OriginalPixel['blue']); 
    276276        return array('red'=>$gray, 'green'=>$gray, 'blue'=>$gray); 
    277277    } 
    278278 
    279279 
    280     function GrayscalePixelRGB($rgb) { 
     280    public static function GrayscalePixelRGB($rgb) { 
    281281        $r = ($rgb >> 16) & 0xFF; 
    282282        $g = ($rgb >>  8) & 0xFF; 
     
    286286 
    287287 
    288     function ScaleToFitInBox($width, $height, $maxwidth=null, $maxheight=null, $allow_enlarge=true, $allow_reduce=true) { 
     288    public static function ScaleToFitInBox($width, $height, $maxwidth=null, $maxheight=null, $allow_enlarge=true, $allow_reduce=true) { 
    289289        $maxwidth  = (is_null($maxwidth)  ? $width  : $maxwidth); 
    290290        $maxheight = (is_null($maxheight) ? $height : $maxheight); 
     
    307307    } 
    308308 
    309     function ImageCopyResampleBicubic($dst_img, $src_img, $dst_x, $dst_y, $src_x, $src_y, $dst_w, $dst_h, $src_w, $src_h) { 
     309    public static function ImageCopyResampleBicubic($dst_img, $src_img, $dst_x, $dst_y, $src_x, $src_y, $dst_w, $dst_h, $src_w, $src_h) { 
    310310        // ron at korving dot demon dot nl 
    311311        // http://www.php.net/imagecopyresampled 
     
    359359 
    360360 
    361     function ImageCreateFunction($x_size, $y_size) { 
     361    public static function ImageCreateFunction($x_size, $y_size) { 
    362362        $ImageCreateFunction = 'ImageCreate'; 
    363         if (phpthumb_functions::gd_version() >= 2.0) { 
     363        if (self::gd_version() >= 2.0) { 
    364364            $ImageCreateFunction = 'ImageCreateTrueColor'; 
    365365        } 
     
    374374 
    375375 
    376     function ImageCopyRespectAlpha(&$dst_im, &$src_im, $dst_x, $dst_y, $src_x, $src_y, $src_w, $src_h, $opacity_pct=100) { 
     376    public static function ImageCopyRespectAlpha(&$dst_im, &$src_im, $dst_x, $dst_y, $src_x, $src_y, $src_w, $src_h, $opacity_pct=100) { 
    377377        $opacipct = $opacity_pct / 100; 
    378378        for ($x = $src_x; $x < $src_w; $x++) { 
    379379            for ($y = $src_y; $y < $src_h; $y++) { 
    380                 $RealPixel    = phpthumb_functions::GetPixelColor($dst_im, $dst_x + $x, $dst_y + $y); 
    381                 $OverlayPixel = phpthumb_functions::GetPixelColor($src_im, $x, $y); 
     380                $RealPixel    = self::GetPixelColor($dst_im, $dst_x + $x, $dst_y + $y); 
     381                $OverlayPixel = self::GetPixelColor($src_im, $x, $y); 
    382382                $alphapct = $OverlayPixel['alpha'] / 127; 
    383383                $overlaypct = (1 - $alphapct) * $opacipct; 
    384384 
    385                 $newcolor = phpthumb_functions::ImageColorAllocateAlphaSafe( 
     385                $newcolor = self::ImageColorAllocateAlphaSafe( 
    386386                    $dst_im, 
    387387                    round($RealPixel['red']   * (1 - $overlaypct)) + ($OverlayPixel['red']   * $overlaypct), 
     
    398398 
    399399 
    400     function ProportionalResize($old_width, $old_height, $new_width=false, $new_height=false) { 
     400    public static function ProportionalResize($old_width, $old_height, $new_width=false, $new_height=false) { 
    401401        $old_aspect_ratio = $old_width / $old_height; 
    402402        if (($new_width === false) && ($new_height === false)) { 
     
    421421 
    422422 
    423     function FunctionIsDisabled($function) { 
     423    public static function FunctionIsDisabled($function) { 
    424424        static $DisabledFunctions = null; 
    425425        if (is_null($DisabledFunctions)) { 
     
    441441 
    442442 
    443     function SafeExec($command) { 
     443    public static function SafeExec($command) { 
    444444        static $AllowedExecFunctions = array(); 
    445445        if (empty($AllowedExecFunctions)) { 
    446446            $AllowedExecFunctions = array('shell_exec'=>true, 'passthru'=>true, 'system'=>true, 'exec'=>true); 
    447447            foreach ($AllowedExecFunctions as $key => $value) { 
    448                 $AllowedExecFunctions[$key] = !phpthumb_functions::FunctionIsDisabled($key); 
     448                $AllowedExecFunctions[$key] = !self::FunctionIsDisabled($key); 
    449449            } 
    450450        } 
     
    482482 
    483483 
    484     function ApacheLookupURIarray($filename) { 
     484    public static function ApacheLookupURIarray($filename) { 
    485485        // apache_lookup_uri() only works when PHP is installed as an Apache module. 
    486486        if (php_sapi_name() == 'apache') { 
     
    498498 
    499499 
    500     function gd_is_bundled() { 
     500    public static function gd_is_bundled() { 
    501501        static $isbundled = null; 
    502502        if (is_null($isbundled)) { 
     
    508508 
    509509 
    510     function gd_version($fullstring=false) { 
     510    public static function gd_version($fullstring=false) { 
    511511        static $cache_gd_version = array(); 
    512512        if (empty($cache_gd_version)) { 
     
    524524 
    525525 
    526     function filesize_remote($remotefile, $timeout=10) { 
     526    public static function filesize_remote($remotefile, $timeout=10) { 
    527527        $size = false; 
    528         $url = phpthumb_functions::ParseURLbetter($remotefile); 
     528        $url = self::ParseURLbetter($remotefile); 
    529529        if ($fp = @fsockopen($url['host'], ($url['port'] ? $url['port'] : 80), $errno, $errstr, $timeout)) { 
    530530            fwrite($fp, 'HEAD '.@$url['path'].@$url['query'].' HTTP/1.0'."\r\n".'Host: '.@$url['host']."\r\n\r\n"); 
    531             if (phpthumb_functions::version_compare_replacement(phpversion(), '4.3.0', '>=')) { 
     531            if (self::version_compare_replacement(phpversion(), '4.3.0', '>=')) { 
    532532                stream_set_timeout($fp, $timeout); 
    533533            } 
     
    545545 
    546546 
    547     function filedate_remote($remotefile, $timeout=10) { 
     547    public static function filedate_remote($remotefile, $timeout=10) { 
    548548        $date = false; 
    549         $url = phpthumb_functions::ParseURLbetter($remotefile); 
     549        $url = self::ParseURLbetter($remotefile); 
    550550        if ($fp = @fsockopen($url['host'], ($url['port'] ? $url['port'] : 80), $errno, $errstr, $timeout)) { 
    551551            fwrite($fp, 'HEAD '.@$url['path'].@$url['query'].' HTTP/1.0'."\r\n".'Host: '.@$url['host']."\r\n\r\n"); 
    552             if (phpthumb_functions::version_compare_replacement(phpversion(), '4.3.0', '>=')) { 
     552            if (self::version_compare_replacement(phpversion(), '4.3.0', '>=')) { 
    553553                stream_set_timeout($fp, $timeout); 
    554554            } 
     
    566566 
    567567 
    568     function md5_file_safe($filename) { 
     568    public static function md5_file_safe($filename) { 
    569569        // md5_file() doesn't exist in PHP < 4.2.0 
    570570        if (function_exists('md5_file')) { 
     
    584584 
    585585 
    586     function nonempty_min() { 
     586    public static function nonempty_min() { 
    587587        $arg_list = func_get_args(); 
    588588        $acceptable = array(); 
     
    596596 
    597597 
    598     function LittleEndian2String($number, $minbytes=1) { 
     598    public static function LittleEndian2String($number, $minbytes=1) { 
    599599        $intstring = ''; 
    600600        while ($number > 0) { 
     
    605605    } 
    606606 
    607     function OneOfThese() { 
     607    public static function OneOfThese() { 
    608608        // return the first useful (non-empty/non-zero/non-false) value from those passed 
    609609        $arg_list = func_get_args(); 
     
    616616    } 
    617617 
    618     function CaseInsensitiveInArray($needle, $haystack) { 
     618    public static function CaseInsensitiveInArray($needle, $haystack) { 
    619619        $needle = strtolower($needle); 
    620620        foreach ($haystack as $key => $value) { 
     
    628628    } 
    629629 
    630     function URLreadFsock($host, $file, &$errstr, $successonly=true, $port=80, $timeout=10) { 
    631         if (!function_exists('fsockopen') || phpthumb_functions::FunctionIsDisabled('fsockopen')) { 
     630    public static function URLreadFsock($host, $file, &$errstr, $successonly=true, $port=80, $timeout=10) { 
     631        if (!function_exists('fsockopen') || self::FunctionIsDisabled('fsockopen')) { 
    632632            $errstr = 'fsockopen() unavailable'; 
    633633            return false; 
     
    679679    } 
    680680 
    681     function CleanUpURLencoding($url, $queryseperator='&') { 
     681    public static function CleanUpURLencoding($url, $queryseperator='&') { 
    682682        if (!eregi('^http', $url)) { 
    683683            return $url; 
    684684        } 
    685         $parse_url = phpthumb_functions::ParseURLbetter($url); 
     685        $parse_url = self::ParseURLbetter($url); 
    686686        $pathelements = explode('/', $parse_url['path']); 
    687687        $CleanPathElements = array(); 
     
    716716    } 
    717717 
    718     function ParseURLbetter($url) { 
     718    public static function ParseURLbetter($url) { 
    719719        $parsedURL = @parse_url($url); 
    720720        if (!@$parsedURL['port']) { 
     
    734734    } 
    735735 
    736     function SafeURLread($url, &$error, $timeout=10, $followredirects=true) { 
     736    public static function SafeURLread($url, &$error, $timeout=10, $followredirects=true) { 
    737737        $error = ''; 
    738738 
    739         $parsed_url = phpthumb_functions::ParseURLbetter($url); 
     739        $parsed_url = self::ParseURLbetter($url); 
    740740        $alreadyLookedAtURLs[trim($url)] = true; 
    741741 
    742742        while (true) { 
    743743            $tryagain = false; 
    744             $rawData = phpthumb_functions::URLreadFsock(@$parsed_url['host'], @$parsed_url['path'].'?'.@$parsed_url['query'], $errstr, true, (@$parsed_url['port'] ? @$parsed_url['port'] : 80), $timeout); 
     744            $rawData = self::URLreadFsock(@$parsed_url['host'], @$parsed_url['path'].'?'.@$parsed_url['query'], $errstr, true, (@$parsed_url['port'] ? @$parsed_url['port'] : 80), $timeout); 
    745745            if (eregi('302 [a-z ]+; Location\\: (http.*)', $errstr, $matches)) { 
    746746                $matches[1] = trim(@$matches[1]); 
     
    751751                    $tryagain = true; 
    752752                    $alreadyLookedAtURLs[$matches[1]] = true; 
    753                     $parsed_url = phpthumb_functions::ParseURLbetter($matches[1]); 
     753                    $parsed_url = self::ParseURLbetter($matches[1]); 
    754754                } 
    755755            } 
     
    769769        } 
    770770 
    771         if (function_exists('curl_version') && !phpthumb_functions::FunctionIsDisabled('curl_exec')) { 
     771        if (function_exists('curl_version') && !self::FunctionIsDisabled('curl_exec')) { 
    772772            $ch = curl_init(); 
    773773            curl_setopt($ch, CURLOPT_URL, $url); 
     
    817817    } 
    818818 
    819     function EnsureDirectoryExists($dirname) { 
     819    public static function EnsureDirectoryExists($dirname) { 
    820820        $directory_elements = explode(DIRECTORY_SEPARATOR, $dirname); 
    821821        $startoffset = (!$directory_elements[0] ? 2 : 1);  // unix with leading "/" then start with 2nd element; Windows with leading "c:\" then start with 1st element 
     
    850850 
    851851 
    852     function GetAllFilesInSubfolders($dirname) { 
     852    public static function GetAllFilesInSubfolders($dirname) { 
    853853        $AllFiles = array(); 
    854854        $dirname = rtrim(realpath($dirname), '/\\'); 
     
    866866                        default: 
    867867                            $AllFiles[] = $fullfilename; 
    868                             $subfiles = phpthumb_functions::GetAllFilesInSubfolders($fullfilename); 
     868                            $subfiles = self::GetAllFilesInSubfolders($fullfilename); 
    869869                            foreach ($subfiles as $filename) { 
    870870                                $AllFiles[] = $filename; 
     
    883883 
    884884 
    885     function SanitizeFilename($filename) { 
     885    public static function SanitizeFilename($filename) { 
    886886        $filename = ereg_replace('[^'.preg_quote(' !#$%^()+,-.;<>=@[]_{}').'a-zA-Z0-9]', '_', $filename); 
    887         if (phpthumb_functions::version_compare_replacement(phpversion(), '4.1.0', '>=')) { 
     887        if (self::version_compare_replacement(phpversion(), '4.1.0', '>=')) { 
    888888            $filename = trim($filename, '.'); 
    889889        } 
     
    916916                'XBM Support'        => false 
    917917            ); 
    918             $phpinfo_array = phpthumb_functions::phpinfo_array(); 
     918            $phpinfo_array = self::phpinfo_array(); 
    919919            foreach ($phpinfo_array as $line) { 
    920920                $line = trim(strip_tags($line)); 
  • faviroll/trunk/readme.txt

    r824929 r827644  
    55Requires at least: 3.x 
    66Tested up to: 3.8 
    7 Stable tag: 0.5.2 
     7Stable tag: 0.5.2.1 
    88 
    99== Description == 
     
    20203. faviroll backend panel with favicon cache 
    21214. manage-links panel have favicons decoration also 
     225. caution messages if something is wrong  
    2223 
    2324== Installation == 
     
    3536* CLN = Cleanup/Refactoring 
    3637* OTH = Other 
     38 
     39= 0.5.2.1 = 
     40* OPT: Preventive examination whether url_fopen is possible. If not you will got feedback. 
     41* CLN: Code maintenance. 
    3742 
    3843= 0.5.2 = 
Note: See TracChangeset for help on using the changeset viewer.