Пример #1
0
 static function getImageThumbMax($imagePath, $title = '', $full_with_domain = true, $server_no = 0)
 {
     if ($imagePath && isset(CGlobal::$img_server[$server_no]) && CGlobal::$img_server[$server_no]) {
         if ($title != '') {
             $title = $title ? AZLib::base64_url_encode(str_replace(array('"', "'"), array('"', '\\\''), stripslashes($title))) : '';
             $file_ext = AZLib::getExtension($imagePath);
             $imagePath = dirname($imagePath) . '/' . basename($imagePath, $file_ext) . ',' . $title . $file_ext;
         }
         //return ($full_with_domain?'http://'.IMAGE_PATH:'')."thumb_max/1200_800/$imagePath";
         return ($full_with_domain ? CGlobal::$img_server[$server_no] : '') . "thumb_max/{$imagePath}";
     }
     return '';
 }