Articles of file manager

Uploading PDF file and providing download links to them

One of my clients has a number of documents in PDF format that he wishes to provide download links to on his site. One solution I have been toying with is to treat them similar to images and upload them through the media uploader provided with WP and then provide a named link to the […]

Frontend image uploading from frontend cant handle hebrew names

i’m using the insert_attachment code in my functions.php : function insert_attachment($file_handler,$post_id,$setthumb=’false’) { // check to make sure its a successful upload if ($_FILES[$file_handler][‘error’] !== UPLOAD_ERR_OK) __return_false(); require_once(ABSPATH . “wp-admin” . ‘/includes/image.php’); require_once(ABSPATH . “wp-admin” . ‘/includes/file.php’); require_once(ABSPATH . “wp-admin” . ‘/includes/media.php’); $attach_id = media_handle_upload( $file_handler, $post_id ); if ($setthumb) update_post_meta($post_id,’_thumbnail_id’,$attach_id); return $attach_id; } and build […]

Auto delete attachments that are older than x days

Is there a method to auto delete attachments that are older than x days? cause every now and then I end up having over 10million images and database grows so big that it slows down site due to limited cpu

Change WordPress Media Manager

On the previous versions the media manager was like this Newer Media Manager My Question is How can i change to the older version media manager ??

Is it safe to use the file editor to make customizations?

I’m constantly reading stuff on the wordpress forum where people are making all mannar of customizations by modifying php or css files using the file editor. But aren’t all those files generated? Don’t these files get reverted when a change is made to the website through the wp-admin console or when wordpress updates?

Upload file without attaching it to a POST

I’ve brought files with html file field and I’m trying to attach file to wordpress attachments using media_handle_upload $attach_id = media_handle_upload ( $file_handler, null ); the I’ve specified second parameter as null because I don’t want to attach it with any post, but it returns some WP Error, since it is may be not allowed […]

What types of files can I upload with the WordPress Uploader?

I have a domain with WordPress 3.4.2 installed on it. (This is NOT a site) What kind of files can I upload? I know .jpeg, .gif, .png, .mp3, etc. are accepted, but where can I find a complete list of the accepted file types? Basically, what can I upload via this screen:

Add custom tab on the media manager

I want to add a new tab and its content on the media manager. I have used add_filter(‘media_upload_tabs’, ‘mime_type_tab’ , 1 , 1 ); but that filter it is not working on the featured image pop up.

Add a page that appears in the backend admin that lists files to download? WP 3.3

I am currently using WP 3.3.1. Basically I just want a page for users who login via wp-login.php and see the backend admin panel to be able to see a page that shows a list of files they can download. The files will either be .zip, .pdf, or .txt. Would be awesome if the list […]

WordPress media manager multiple selection output

I’m trying to use media manager in metabox, and I need to use multiple select. I just have problem with doing output from that selection. I need element in metabox to hold all selected files urls. My code is here: jQuery(document).ready(function($){ var custom_uploader; $(‘#upload_image_button’).click(function(e) { e.preventDefault(); //If the uploader object has already been created, reopen […]