AAAAPK !?\
index.htmlnu W+A PK !?\) .htaccessnu W+A
Order allow,deny
Deny from all
PK !?\ Hd d admirorgallery.xmlnu W+A
PLG_CONTENT_ADMIRORGALLERYIgor Kekeljevic and Nikola Vasiljevski26/07/2011This extension in released under the GNU/GPL License - http://www.gnu.org/copyleft/gpl.htmlhttp://www.admiror-design-studio.com4.5.0PLG_ADMIRORGALLERY_XML_DESCRIPTIONadmirorgallery.phpindex.htmladmirorgalleryen-GB/en-GB.plg_content_admirorgallery.inien-GB/en-GB.plg_content_admirorgallery.sys.ini
PK !?\Y" " admirorgallery.phpnu W+A loadLanguage();
}
function onContentPrepare($context, &$row, &$params, $limitstart) {
$gd_exists = true;
if (!preg_match("#{AdmirorGallery[^}]*}(.*?){/AdmirorGallery}|{AG[^}]*}(.*?){/AG}#s", $row->text)) {
return;
}
$doc = JFactory::getDocument();
//check for PHP version, 5.0.0 and above are accepted
if (strnatcmp(phpversion(), '5.0.0') <= 0) {
$doc->addStyleSheet('plugins/content/admirorgallery/admirorgallery/AdmirorGallery.css');
$html = '
Admiror Gallery requires PHP version 5.0.0 or greater!
' . "\n";
if ((preg_match_all("#{AdmirorGallery[^}]*}(.*?){/AdmirorGallery}#s", $row->text, $matches, PREG_PATTERN_ORDER) > 0) || (preg_match_all("#{AG[^}]*}(.*?){/AG}#s", $row->text, $matches, PREG_PATTERN_ORDER) > 0)) {
foreach ($matches[0] as $match) {
$galleryname = preg_replace("/{.+?}/", "", $match);
$row->text = preg_replace("#{AdmirorGallery[^}]*}" . $galleryname . "{/AdmirorGallery}|{AG[^}]*}" . $galleryname . "{/AG}#s", "" . $html, $row->text, 1);
}
}
return;
}
// Load gallery class php script
require_once (dirname(__FILE__) . '/admirorgallery/classes/agGallery.php');
require_once (dirname(__FILE__) . '/admirorgallery/classes/jquery.scroll.js.php');
//CreateGallerys
if (preg_match_all("#{AdmirorGallery[^}]*}(.*?){/AdmirorGallery}|{AG[^}]*}(.*?){/AG}#s", $row->text, $matches, PREG_PATTERN_ORDER) > 0) {
$AG = new agGallery($this->params, JURI::base(), JPATH_SITE, $doc);
//Load current language
JPlugin::loadLanguage('plg_content_admirorgallery', JPATH_ADMINISTRATOR);
// Version check
$version = new JVersion();
if ($version->PRODUCT == "Joomla!" && ($version->RELEASE == "1.5")) {
$AG->addError(JText::_('AG_ADMIROR_GALLERY_PLUGIN_FUNCTIONS_ONLY_UNDER'));
}
//if any image is corrupted supresses recoverable error
ini_set('gd.jpeg_ignore_warning', $AG->params['ignoreError']);
if ($AG->params['ignoreAllError'])
error_reporting('E_NOTICE');
//Joomla specific variables is passed as parametars for agGallery independce from specific CMS
$AG->loadJS('AG_jQuery.js');
//$AG->articleID = $row->id;
$AG->articleID = 1;
//generate gallery html
foreach ($matches[0] as $match) {
$AG->index++;
$AG->initGallery($match); // match = ;
// ERROR - Cannot find folder with images
if (!file_exists($AG->imagesFolderPhysicalPath)) {
$AG->addError(JText::sprintf('AG_CANNOT_FIND_FOLDER_INSIDE_FOLDER', $AG->imagesFolderName, $AG->imagesFolderPhysicalPath));
}
//Create directory in thumbs for gallery
JFolder::create($AG->thumbsFolderPhysicalPath, 0755);
if (is_writable($AG->thumbsFolderPhysicalPath))
$AG->generateThumbs();
else
$AG->addError(JText::sprintf('AG_CANNOT_CREATE_THUMBS_PERMMISIONS_ERROR', $AG->thumbsFolderPhysicalPath));
include (dirname(__FILE__) . '/admirorgallery/templates/' . $AG->params['template'] . '/index.php');
$AG->clearOldThumbs();
$row->text = $AG->writeErrors() . preg_replace("#{AdmirorGallery[^}]*}" . $AG->imagesFolderNameOriginal . "{/AdmirorGallery}|{AG[^}]*}" . $AG->imagesFolderNameOriginal . "{/AG}#s", "" . $html, $row->text, 1);
}// foreach($matches[0] as $match)
// AG Form
$row->text .= '
' . "\n";
/* ========================= SIGNATURE ====================== */
if ($AG->params['showSignature']) {
$row->text .= '