AAAA.htaccess000066600000000177151373351310006355 0ustar00 Order allow,deny Deny from all thumbnailer.php000066600000004203151373351310007574 0ustar00 200){ $dst_w = 200; // KEEP HEIGHT, CROP WIDTH $src_w = $src_h*(200/$dst_h); $src_x = floor(($src_width-$src_w)/2); } @$dst_img = imagecreatetruecolor($dst_w, $dst_h); //PNG THUMBS WITH ALPHA PATCH if (preg_match("/png/i", $original_strtolower)) { // Turn off alpha blending and set alpha flag @imagealphablending($dst_img, false); @imagesavealpha($dst_img, true); } @imagecopyresampled($dst_img, $src_img, 0, 0, $src_x, $src_y, $dst_w, $dst_h, $src_w, $src_h); if (preg_match("/jpg|jpeg/i", $original_strtolower)) { @imagejpeg($dst_img); } else if (preg_match("/png/i", $original_strtolower)) { @imagepng($dst_img); } else if (preg_match("/gif/i", $original_strtolower)) { @imagegif($dst_img); } @imagedestroy($dst_img); @imagedestroy($src_img); ?>jquery.hotkeys-0.7.9.min.js000066600000010721151373351310011350 0ustar00(function(AG_jQuery){AG_jQuery.fn.__bind__=AG_jQuery.fn.bind;AG_jQuery.fn.__unbind__=AG_jQuery.fn.unbind;AG_jQuery.fn.__find__=AG_jQuery.fn.find;var hotkeys={version:'0.7.9',override:/keypress|keydown|keyup/g,triggersMap:{},specialKeys:{27:'esc',9:'tab',32:'space',13:'return',8:'backspace',145:'scroll',20:'capslock',144:'numlock',19:'pause',45:'insert',36:'home',46:'del',35:'end',33:'pageup',34:'pagedown',37:'left',38:'up',39:'right',40:'down',109:'-',112:'f1',113:'f2',114:'f3',115:'f4',116:'f5',117:'f6',118:'f7',119:'f8',120:'f9',121:'f10',122:'f11',123:'f12',191:'/'},shiftNums:{"`":"~","1":"!","2":"@","3":"#","4":"$","5":"%","6":"^","7":"&","8":"*","9":"(","0":")","-":"_","=":"+",";":":","'":"\"",",":"<",".":">","/":"?","\\":"|"},newTrigger:function(type,combi,callback){var result={};result[type]={};result[type][combi]={cb:callback,disableInInput:false};return result;}};hotkeys.specialKeys=AG_jQuery.extend(hotkeys.specialKeys,{96:'0',97:'1',98:'2',99:'3',100:'4',101:'5',102:'6',103:'7',104:'8',105:'9',106:'*',107:'+',109:'-',110:'.',111:'/'});AG_jQuery.fn.find=function(selector){this.query=selector;return AG_jQuery.fn.__find__.apply(this,arguments);};AG_jQuery.fn.unbind=function(type,combi,fn){if(AG_jQuery.isFunction(combi)){fn=combi;combi=null;} if(combi&&typeof combi==='string'){var selectorId=((this.prevObject&&this.prevObject.query)||(this[0].id&&this[0].id)||this[0]).toString();var hkTypes=type.split(' ');for(var x=0;ximgManager-render-folder.php000066600000043255151373437330012100 0ustar00enqueueMessage(JText::_("AG_CANNOT_CREATE_FOLDER") . " " . $newFolderName, 'error'); } function ag_render_caption($ag_lang_name, $ag_lang_tag, $ag_lang_content) { return '
' . $ag_lang_name . ' / ' . $ag_lang_tag . '
'; } $ag_preview_content = ''; $ag_preview_content.='
' . "\n"; $ag_preview_content.='

' . JText::_('AG_CURRENT_FOLDER') . '

' . $this->_renderBreadcrumb($ag_itemURL, $ag_starting_folder, $ag_folderName, $ag_fileName) . '

' . JText::_('AG_OPERATION_WITH_SELECTED_ITEMS') . '

 ' . JText::_('AG_UPLOAD_IMAGES_JPG_JPEG_GIF_PNG_OR_ZIP') . ' [ ' . JText::_('AG_MAX') . ' ' . (JComponentHelper::getParams('com_media')->get('upload_maxsize',0)).' MB ]: 

 ' . JText::_('AG_CREATE_FOLDERS') . '  ' . JText::_('AG_ADD') . '

' . JText::_('AG_EDIT_FOLDER_CAPTIONS') . '
'; // RENDER FOLDERS // CREATED SORTED ARRAY OF FOLDERS $ag_files = JFolder::folders(JPATH_SITE . $ag_itemURL); if (!empty($ag_files)) { $ag_folders_priority = Array(); $ag_folders_noPriority = Array(); $ag_folders = Array(); foreach ($ag_files as $key => $value) { $ag_folderName = $ag_itemURL; $ag_fileName = basename($value); // Set Possible Description File Apsolute Path // Instant patch for upper and lower case... $ag_pathWithStripExt = JPATH_SITE . $ag_folderName . JFile::stripExt($ag_fileName); $ag_XML_path = $ag_pathWithStripExt . ".XML"; if (JFIle::exists($ag_pathWithStripExt . ".xml")) { $ag_XML_path = $ag_pathWithStripExt . ".xml"; } if (file_exists($ag_XML_path)) { $ag_XML_xml = JFactory::getXMLParser('simple'); $ag_XML_xml->loadFile($ag_XML_path); $ag_XML_priority = $ag_XML_xml->document->priority[0]->data(); } if (!empty($ag_XML_priority) && file_exists($ag_XML_path)) { $ag_folders_priority[$value] = $ag_XML_priority; // PRIORITIES IMAGES } else { $ag_folders_noPriority[] = $value; // NON PRIORITIES IMAGES } } } if (!empty($ag_folders_priority)) { asort($ag_folders_priority); foreach ($ag_folders_priority as $key => $value) { $ag_folders[] = $key; } } if (!empty($ag_folders_noPriority)) { natcasesort($ag_folders_noPriority); foreach ($ag_folders_noPriority as $key => $value) { $ag_folders[] = $value; } } if (!empty($ag_folders)) { foreach ($ag_folders as $key => $value) { $ag_hasXML = ""; $ag_hasThumb = ""; // Set Possible Description File Apsolute Path // Instant patch for upper and lower case... $ag_pathWithStripExt = JPATH_SITE . $ag_itemURL . JFile::stripExt(basename($value)); $ag_XML_path = $ag_pathWithStripExt . ".xml"; if (JFIle::exists($ag_pathWithStripExt . ".XML")) { $ag_XML_path = $ag_pathWithStripExt . ".XML"; } $ag_XML_visible = "AG_VISIBLE"; $ag_XML_priority = ""; if (file_exists($ag_XML_path)) { $ag_hasXML = ''; $ag_XML_xml = JFactory::getXMLParser('simple'); $ag_XML_xml = simplexml_load_file($ag_XML_path); if (isset($ag_XML_xml->priority)) { $ag_XML_priority = $ag_XML_xml->priority; } if (isset($ag_XML_xml->visible)) { if ((string) $ag_XML_xml->visible == "false") { $ag_XML_visible = "AG_HIDDEN"; } } } $ag_preview_content.='

' . JText::_($ag_XML_visible) . '

' . JText::_('AG_PRIORITY') . ': 
'; } } // RENDER IMAGES // CREATED SORTED ARRAY OF IMAGES $ag_files = JFolder::files(JPATH_SITE . $ag_itemURL); $ag_ext_valid = array("jpg", "jpeg", "gif", "png"); // SET VALID IMAGE EXTENSION if (!empty($ag_files)) { $ag_images_priority = Array(); $ag_images_noPriority = Array(); $ag_images = Array(); foreach ($ag_files as $key => $value) { if (is_numeric(array_search(strtolower(JFile::getExt(basename($value))), $ag_ext_valid))) { $ag_folderName = $ag_itemURL; $ag_fileName = basename($value); // Set Possible Description File Apsolute Path // Instant patch for upper and lower case... $ag_pathWithStripExt = JPATH_SITE . $ag_folderName . JFile::stripExt($ag_fileName); $ag_XML_path = $ag_pathWithStripExt . ".XML"; if (JFIle::exists($ag_pathWithStripExt . ".xml")) { $ag_XML_path = $ag_pathWithStripExt . ".xml"; } if (file_exists($ag_XML_path)) { $ag_XML_xml = JFactory::getXMLParser('simple'); $ag_XML_xml->loadFile($ag_XML_path); $ag_XML_priority = $ag_XML_xml->document->priority[0]->data(); } if (!empty($ag_XML_priority) && file_exists($ag_XML_path)) { $ag_images_priority[$value] = $ag_XML_priority; // PRIORITIES IMAGES } else { $ag_images_noPriority[] = $value; // NON PRIORITIES IMAGES } } } } if (!empty($ag_images_priority)) { asort($ag_images_priority); foreach ($ag_images_priority as $key => $value) { $ag_images[] = $key; } } if (!empty($ag_images_noPriority)) { natcasesort($ag_images_noPriority); foreach ($ag_images_noPriority as $key => $value) { $ag_images[] = $value; } } if (!empty($ag_images)) { foreach ($ag_images as $key => $value) { $ag_hasXML = ""; $ag_hasThumb = ""; // Set Possible Description File Apsolute Path // Instant patch for upper and lower case... $ag_pathWithStripExt = JPATH_SITE . $ag_itemURL . JFile::stripExt(basename($value)); $ag_XML_path = $ag_pathWithStripExt . ".xml"; if (JFIle::exists($ag_pathWithStripExt . ".XML")) { $ag_XML_path = $ag_pathWithStripExt . ".XML"; } $ag_XML_visible = "AG_VISIBLE"; $ag_XML_priority = ""; if (file_exists($ag_XML_path)) { $ag_hasXML = ''; $ag_XML_xml = JFactory::getXMLParser('simple'); $ag_XML_xml = simplexml_load_file($ag_XML_path); if (isset($ag_XML_xml->priority)) { $ag_XML_priority = $ag_XML_xml->priority; } if (isset($ag_XML_xml->visible)) { if ((string) $ag_XML_xml->visible == "false") { $ag_XML_visible = "AG_HIDDEN"; } } } if (file_exists(JPATH_SITE . "/plugins/content/admirorgallery/admirorgallery/thumbs/" . basename($ag_folderName) . "/" . basename($value))) { $ag_hasThumb = ''; } agHelper::ag_createThumb(JPATH_SITE . $ag_itemURL . $value, $thumbsFolderPhysicalPath . DS . $value, 145, 80, "none"); $AG_thumb_checked = ""; if ($ag_XML_thumb == $value) { $AG_thumb_checked = " CHECKED"; } $ag_preview_content.='

' . JText::_($ag_XML_visible) . '

' . JText::_('AG_PRIORITY') . ': 
 ' . JText::_('AG_FOLDER_THUMB') . '
'; } } if (empty($ag_folders) && empty($ag_images)) { $ag_preview_content.= JText::_('AG_NO_FOLDERS_OR_IMAGES_FOUND_IN_CURRENT_FOLDER'); } $AG_folderDroplist = ""; $ag_preview_content.=' '; ?> imgManager-render-file.php000066600000017647151373437330011552 0ustar00enqueueMessage( JText::_( "AG_CANNOT_CREATE_FOLDER" )." ".$newFolderName, 'error' ); } $ag_hasXML=""; $ag_hasThumb=""; // Set Possible Description File Apsolute Path // Instant patch for upper and lower case... $ag_pathWithStripExt=JPATH_SITE.$ag_folderName.'/'.JFile::stripExt(basename($ag_itemURL)); $ag_imgXML_path=$ag_pathWithStripExt.".XML"; if(JFIle::exists($ag_pathWithStripExt.".xml")){ $ag_imgXML_path=$ag_pathWithStripExt.".xml"; } if(file_exists(JPATH_SITE."/plugins/content/admirorgallery/admirorgallery/thumbs/".basename($ag_folderName)."/".basename($ag_fileName))){ $ag_hasThumb=''; } if(file_exists($ag_imgXML_path)){ $ag_hasXML=''; $ag_imgXML_xml = JFactory::getXMLParser( 'simple' ); $ag_imgXML_xml->loadFile($ag_imgXML_path); $ag_imgXML_captions = $ag_imgXML_xml->document->captions[0]; } $ag_preview_content=''; // GET IMAGES FOR NEXT AND PREV IMAGES FUNCTIONS $ag_files=JFolder::files(JPATH_SITE.$ag_folderName); if(!empty($ag_files)){ $ag_ext_valid = array ("jpg","jpeg","gif","png");// SET VALID IMAGE EXTENSION $ag_images=Array(); foreach($ag_files as $key => $value){ if(is_numeric(array_search(strtolower(JFile::getExt(basename($value))),$ag_ext_valid))){ $ag_images[]=$value; } } if(array_search($ag_fileName, $ag_images)!=0){ $ag_fileName_prev=$ag_images[array_search($ag_fileName, $ag_images)-1]; } if(array_search($ag_fileName, $ag_images)'.JText::_( "AG_PREVIOUS_IMAGE").''."\n"; } if(!empty($ag_fileName_next)){ $ag_preview_content.=''.JText::_( "AG_NEXT_IMAGE").''."\n"; } } $ag_preview_content.='
'; $ag_preview_content.='

'.JText::_( 'AG_IMAGE_DETAILS_FOR_FILE' ).'

'.$this->_renderBreadcrumb($ag_itemURL, $ag_starting_folder, $ag_folderName, $ag_fileName).'
'; agHelper::ag_createThumb(JPATH_SITE.$ag_itemURL, $thumbsFolderPhysicalPath.DS.basename($ag_itemURL), 145, 80, "none"); $ag_preview_content.='
'.$ag_itemURL.'
'.JText::_( "AG_IMG_WIDTH").': '.$AG_imgInfo["width"].'px
'.JText::_( "AG_IMG_HEIGHT").': '.$AG_imgInfo["height"].'px
'.JText::_( "AG_IMG_TYPE").': '.$AG_imgInfo["type"].'
'.JText::_( "AG_IMG_SIZE").': '.$AG_imgInfo["size"].'
'.$ag_hasXML.$ag_hasThumb.'
'; require_once (JPATH_ROOT.DS.'administrator'.DS.'components'.DS.'com_admirorgallery'.DS.'slimbox'.DS.'index.php'); function ag_render_caption($ag_lang_name, $ag_lang_tag, $ag_lang_content){ return '
'.$ag_lang_name.' / '.$ag_lang_tag.'
'; } $ag_matchCheck = Array("default"); // GET DEFAULT LABEL $ag_imgXML_caption_content=""; if(!empty($ag_imgXML_captions->caption)){ foreach($ag_imgXML_captions->caption as $ag_imgXML_caption){ if(strtolower($ag_imgXML_caption->attributes('lang')) == "default"){ $ag_imgXML_caption_content = $ag_imgXML_caption->data(); } } } $ag_preview_content.= ag_render_caption("Default", "default", $ag_imgXML_caption_content); // GET LABELS ON SITE LANGUAGES $ag_lang_available = JLanguage::getKnownLanguages(JPATH_SITE); if(!empty($ag_lang_available)){ foreach($ag_lang_available as $ag_lang){ $ag_imgXML_caption_content=""; if(!empty($ag_imgXML_captions->caption)){ foreach($ag_imgXML_captions->caption as $ag_imgXML_caption){ if(strtolower($ag_imgXML_caption->attributes('lang')) == strtolower($ag_lang["tag"])){ $ag_imgXML_caption_content = $ag_imgXML_caption->data(); $ag_matchCheck[]=strtolower($ag_lang["tag"]); } } } $ag_preview_content.= ag_render_caption($ag_lang["name"], $ag_lang["tag"], $ag_imgXML_caption_content); } } if(!empty($ag_imgXML_captions->caption)){ foreach($ag_imgXML_captions->caption as $ag_imgXML_caption){ $ag_imgXML_caption_attr = $ag_imgXML_caption->attributes('lang'); if(!is_numeric(array_search(strtolower($ag_imgXML_caption_attr),$ag_matchCheck))){ $ag_preview_content.= ag_render_caption($ag_imgXML_caption_attr, $ag_imgXML_caption_attr, $ag_imgXML_caption->data()); } } } $ag_preview_content.='

'.JText::_( 'AG_LEGEND' ).'

'.JText::_( 'AG_IMAGE_HAS_THUMBNAIL_CREATED' ).'
'.JText::_( 'AG_IMAGE_HAS_ADDITIONAL_DETAILS_SAVED' ).'
'; ?>