Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php
- /**
- * Accepts file uploads from swfupload.
- *
- * @package NextGEN-Gallery
- * @subpackage Administration
- */
- // Flash often fails to send cookies with the POST or upload, so we need to pass it in GET or POST instead
- // We then have to validate the cookie manually. NOTE: WordPress functions, like
- // get_current_user_id() and the like are NOT available in this file.
- if ( is_ssl() && empty($_COOKIE[SECURE_AUTH_COOKIE]) && !empty($_REQUEST['auth_cookie']) )
- [... snip ..]
- header('Content-Type: text/plain; charset=' . get_option('blog_charset'));
- if (wp_validate_auth_cookie()) {
- $results = wp_parse_auth_cookie();
- [... snip ...]
- }
- //check for nggallery
- if ( !defined('NGGALLERY_ABSPATH') )
- die('NextGEN Gallery not available. -3');
- include_once (NGGALLERY_ABSPATH. 'admin/functions.php');
- // get the gallery
- $galleryID = (int) $_POST['galleryselect'];
- echo nggAdmin::swfupload_image($galleryID);
- ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement