Esempio n. 1
0
function uploadDiv()
{
    global $moduleName, $iConfig;
    $maxFileSize = $iConfig['max_file_size'];
    echo '<script type="text/javascript" language="javascript">//<![CDATA[' . PHP_EOL;
    echo '	$(function(){' . PHP_EOL;
    echo '		$(\'.upload-multi-file\').MultiFile({' . PHP_EOL;
    echo '			list: \'#upload-file-list\',' . PHP_EOL;
    echo '			STRING: {' . PHP_EOL;
    echo '				remove: \'<img src="modules/' . $moduleName . '/images/edit-delete.png" style="vertical-align:middle;width:16px;height:16px;" title="' . _IG_DELETE_FROM_QUEUE . '" alt="x" />\'' . PHP_EOL;
    echo '			}' . PHP_EOL;
    echo '		});' . PHP_EOL;
    echo '	});' . PHP_EOL;
    echo '//]]></script>' . PHP_EOL;
    echo '<div id="upload-form-wrapper">' . PHP_EOL;
    echo '	<img src="modules/' . $moduleName . '/images/upload.png" alt="" />' . PHP_EOL;
    echo '	<form id="upload-form" name="upload-form" method="post" enctype="multipart/form-data" action="modules.php?name=' . $moduleName . '&amp;op=uploadMove">' . PHP_EOL;
    echo '		<h3>' . _IG_SELECT_ALBUM . '</h3>' . PHP_EOL;
    getAlbumsDropdown();
    echo '		<br /><br />' . PHP_EOL;
    echo '		<h3>' . _IG_SELECTIMGS . '</h3>' . PHP_EOL;
    echo '		<b>' . _IG_SELECT_UP_TO_10 . '</b><br /><br />' . PHP_EOL;
    echo '		<input type="hidden" name="MAX_FILE_SIZE" value="' . $maxFileSize . '" />' . PHP_EOL;
    echo '		<input name="uploadFiles[]" type="file" class="upload-multi-file" accept="' . allowedExt('browse') . '" maxlength="10" />' . PHP_EOL;
    echo '		<div class="content-box">' . PHP_EOL;
    echo '			<div><b>' . _IG_SELECTED_FILES_APPEAR_HERE . '</b></div>' . PHP_EOL;
    echo '			<div id="upload-file-list"></div>' . PHP_EOL;
    echo '		</div>' . PHP_EOL;
    echo '		<input type="submit" value="' . _IG_UPLOADIMGS . '" />' . PHP_EOL;
    echo '	</form>' . PHP_EOL;
    echo '</div>' . PHP_EOL;
    echo '<div id="upload-alert"><img src="modules/' . $moduleName . '/images/loading.gif" alt="Loading" title="Loading" /></div>' . PHP_EOL;
}
Esempio n. 2
0
function galAlbumDelete($ajaxForm = 0)
{
    global $db, $prefix, $admin_file;
    if (isset($_GET['confirm'])) {
        $confirm = intval($_GET['confirm']);
    }
    $albumDeleteId = intval($_GET['albumid']);
    if (isset($confirm)) {
        $result = $db->sql_query('DELETE FROM ' . $prefix . '_igallery_albums WHERE album_id = ' . $albumDeleteId . ' ;');
    } else {
        include NUKE_BASE_DIR . 'header.php';
        galAdminMenu();
        OpenTable();
        echo '<div id="gal-album-delete">' . PHP_EOL;
        echo '	<h3>' . _IG_ADM_SELECT_DELETE_ACTION . '</h3>' . PHP_EOL;
        echo '	<form id="select-delete-action" method="post" action="">' . PHP_EOL;
        echo '		<input type="radio" name="delete" value="1" /> ' . _IG_ADM_DELETE_ALL_CHILD_AND_PICS . '<br />' . PHP_EOL;
        echo '		<input type="radio" name="delete" value="2" /> ' . _IG_ADM_DELETE_MOVE_CHILD_AND_PICS . '<br />' . PHP_EOL;
        //echo '		<input type="radio" name="delete" value="1" /> _DELETE_ALL_CHILD_AND_PICS'.PHP_EOL;
        //echo '		<input type="radio" name="delete" value="1" /> _DELETE_ALL_CHILD_AND_PICS'.PHP_EOL;
        echo '		<h3>' . _IG_CHILDS_WILL_BE_MOVED_TO . '</h3>' . PHP_EOL;
        echo '		<span>' . _IG_ONLY_IF . ' <b>' . _IG_ADM_DELETE_MOVE_CHILD_AND_PICS . '</b> ' . _IG_ADM_IS_SELECTED_ABOVE . '</span>' . PHP_EOL;
        echo '		<br /><br />' . PHP_EOL;
        getAlbumsDropdown();
        echo '		<br /><br />' . PHP_EOL;
        echo '		<input type="submit" value="' . _IG_SEND . '" />' . PHP_EOL;
        echo '	<form>' . PHP_EOL;
        echo '</div>' . PHP_EOL;
        CloseTable();
        include NUKE_BASE_DIR . 'footer.php';
    }
}