From 9e49ecc8c3362f3bb4522896d4be3d89058460f7 Mon Sep 17 00:00:00 2001 From: Ian Date: Wed, 23 Sep 2015 17:49:23 +0200 Subject: [PATCH] remove to API --- include/admin/images.inc.php | 46 -------------------------------- include/functions_images.inc.php | 46 ++++++++++++++++++++++++++++++++ 2 files changed, 46 insertions(+), 46 deletions(-) diff --git a/include/admin/images.inc.php b/include/admin/images.inc.php index 07956e44..97aaf903 100644 --- a/include/admin/images.inc.php +++ b/include/admin/images.inc.php @@ -707,52 +707,6 @@ switch ($serendipity['GET']['adminAction']) { break; } -/** - * Show the Media Library - * - * @access public - * @param bool default false - * @param array $smarty_vars - * @return string Image list - */ -function showMediaLibrary($addvar_check = false, $smarty_vars = array()) { - global $serendipity; - - if (!serendipity_checkPermission('adminImagesView')) { - return; - } - $output = ''; - - // After upload, do not show the list to be able to proceed to - // media selection. - if ($addvar_check && !empty($GLOBALS['image_selector_addvars'])) { - return true; - } - - if (!isset($serendipity['thumbPerPage'])) { - $serendipity['thumbPerPage'] = 2; - } - $smarty_vars = array( - 'textarea' => isset($serendipity['GET']['textarea']) ? $serendipity['GET']['textarea'] : false, - 'htmltarget' => isset($serendipity['GET']['htmltarget']) ? $serendipity['GET']['htmltarget'] : '', - 'filename_only' => isset($serendipity['GET']['filename_only']) ? $serendipity['GET']['filename_only'] : false, - ); - - $show_upload = isset($serendipity['GET']['showUpload']) ? $serendipity['GET']['showUpload'] : false; - - $output .= serendipity_displayImageList( - isset($serendipity['GET']['page']) ? $serendipity['GET']['page'] : 1, - $serendipity['thumbPerPage'], - isset($serendipity['GET']['showMediaToolbar']) ? serendipity_db_bool($serendipity['GET']['showMediaToolbar']) : true, - NULL, - $show_upload, - NULL, - $smarty_vars - ); - - return $output; -} - if (! isset($data['showML'])) { if (isset($_REQUEST['go_properties'])) { $data['showMLbutton'] = true; diff --git a/include/functions_images.inc.php b/include/functions_images.inc.php index d2b2600b..8c7131b9 100644 --- a/include/functions_images.inc.php +++ b/include/functions_images.inc.php @@ -3618,6 +3618,52 @@ function serendipity_moveMediaDirectory($oldDir, $newDir, $type = 'dir', $item_i return true; } +/** + * Show the Media Library + * + * @access public + * @param bool default false + * @param array $smarty_vars + * @return string Image list + */ +function showMediaLibrary($addvar_check = false, $smarty_vars = array()) { + global $serendipity; + + if (!serendipity_checkPermission('adminImagesView')) { + return; + } + $output = ''; + + // After upload, do not show the list to be able to proceed to + // media selection. + if ($addvar_check && !empty($GLOBALS['image_selector_addvars'])) { + return true; + } + + if (!isset($serendipity['thumbPerPage'])) { + $serendipity['thumbPerPage'] = 2; + } + $smarty_vars = array( + 'textarea' => isset($serendipity['GET']['textarea']) ? $serendipity['GET']['textarea'] : false, + 'htmltarget' => isset($serendipity['GET']['htmltarget']) ? $serendipity['GET']['htmltarget'] : '', + 'filename_only' => isset($serendipity['GET']['filename_only']) ? $serendipity['GET']['filename_only'] : false, + ); + + $show_upload = isset($serendipity['GET']['showUpload']) ? $serendipity['GET']['showUpload'] : false; + + $output .= serendipity_displayImageList( + isset($serendipity['GET']['page']) ? $serendipity['GET']['page'] : 1, + $serendipity['thumbPerPage'], + isset($serendipity['GET']['showMediaToolbar']) ? serendipity_db_bool($serendipity['GET']['showMediaToolbar']) : true, + NULL, + $show_upload, + NULL, + $smarty_vars + ); + + return $output; +} + /** * Gets all available media directories *