<?php
session_start();
define('Admin_USER',true);
require_once("../../../php/defines.php");
require_once("../../../php/classes/mainClass.php");
require_once("../../../php/classes/galleryClass.php");

$gallery = new galleryClass();
$info = $gallery->getImageInfo($_POST['Id']);


$display = '';


$display .= '<div class="popup_form">';
$display .= '<form class="a-r-form" id="PopUp_Form">';
$display .= '<h1 style="text-align:center;">'.$info['Name'].'</h1>';
$display .= '<figure>';
if(is_file(WEBSITE_ADDY.'/gallery/images/medium/'.$info['Name'])){
    
    $display .= '<img src="'.WEBSITE_ADDY.'/gallery/images/medium/'.$info['Name'].'"  class="thumb-img_large" id="Image"/>';
    
}else{
    
    $display .= '<img src="'.WEBSITE_ADDY.'/gallery/images/small/'.$info['Name'].'"  class="thumb-img_large" id="Image"/>';
    
}
$display .= '</figure>';  
$display .= '</form>';
$display .= '</div>';

echo $display;
exit;

?>

