AAAAtmpl/.htaccess000066600000000177151373356350007342 0ustar00 Order allow,deny Deny from all tmpl/index.html000066600000000054151373356350007533 0ustar00tmpl/default.php000066600000022612151373356350007677 0ustar00params); $ag_rootFolder = $pluginParams->get('rootFolder','/images/sampledata/'); if($AG_frontEnd=='true'){ $ag_starting_folder = $pluginParams->get('rootFolder','/images/sampledata/').$this->galleryName.'/'; }else{ $ag_starting_folder = $ag_rootFolder; } if(!empty($AG_itemURL)){ $ag_init_itemURL = $AG_itemURL; }else{ if($AG_frontEnd=='true'){ $ag_init_itemURL = $pluginParams->get('rootFolder','/images/sampledata/').$this->galleryName.'/'; }else{ $ag_init_itemURL = $ag_rootFolder; } } ?>
'.$ag_init_itemURL); $ag_preview_content='
'.$ag_init_itemURL.'
'; return; } echo ' '."\n"; // FORMAT FORM if($AG_frontEnd=='true'){ require_once( JPATH_COMPONENT.DS.'helpers'.DS.'toolbar.php' ); echo '
'.AdmirorgalleryHelperToolbar::getToolbar().'
'; } echo '
'."\n"; // FORMAT SCREEN echo '
'.JText::_( 'AG_SHOW_SIDEBAR').' '.$ag_preview_content.'
'."\n"; ?>
.htaccess000066600000000177151373356350006366 0ustar00 Order allow,deny Deny from all view.html.php000066600000004003151373356350007206 0ustar00'.substr($ag_rootFolder,0,-1).'/'; $ag_breadcrumb_link.=$ag_rootFolder; $ag_breadcrumb_cut=substr($ag_folderName,strlen($ag_rootFolder)); $ag_breadcrumb_cut_array=explode("/",$ag_breadcrumb_cut); if(!empty($ag_breadcrumb_cut_array[0])){ foreach($ag_breadcrumb_cut_array as $cut_key => $cut_value){ $ag_breadcrumb_link.=$cut_value.'/'; $ag_breadcrumb.=''.$cut_value.'/'; } } $ag_breadcrumb.=$ag_fileName; }else{ $ag_breadcrumb.=$ag_rootFolder; } return $ag_breadcrumb; } } scripts/.htaccess000066600000000177151373356350010055 0ustar00 Order allow,deny Deny from all scripts/imgManager-render-folder.php000066600000043255151373356350013571 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.=' '; ?> scripts/imgManager-render-file.php000066600000017647151373356350013243 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' ).'
'; ?> index.html000066600000000054151373356350006557 0ustar00