Media Library is a WordPress panel that display all files you've sent. There you can add ne files, attach files to posts and pages etc

learn more… | top users | synonyms

16
votes
2answers
10k views

How to Protect Uploads, if User is not Logged In?

I use wordpress for a private site where users upload files. I use the "Private WordPress" to prevent access in to the site if the user is not logged in. I would like to do the same to the files ...
20
votes
5answers
7k views

Change the default-view of Media Library in 3.5?

When inserting media into a post, is there a way to change the default-view of the Media-Library from "All media items" to "Uploaded to this post"? There is another thread where this question was ...
15
votes
2answers
2k views

Enhance Media Manager for Gallery

I would like to enhance the Media Editor, after WordPress 3.5, on the gallery view. I want to add a new select field on the right side and send the selected values to the gallery shortcode. I ...
7
votes
5answers
35k views

Get All Images in Media Gallery?

Is there a way to fetch the URLs of ALL images in the media gallery? I think this would be an easy way for a website to have a Pictures page that just pulls all of the images from the media gallery, ...
6
votes
5answers
2k views

Wordpress 3.5 Media Manager - add a button

In my plugin, I would like to add two buttons to Media Manager (to the left of "Insert Into Post" in "media-toolbar-primary" section), and connect a jQuery action to it. First one - The "Select All" ...
5
votes
1answer
17k views

How to use media upload on theme option page?

I want implement upload logo to my theme option page. Currently I follow this code What I have done for now load a related jquery for the media upload function load_only() { add_thickbox(); ...
2
votes
4answers
20k views

How to Fix HTTP Error When Uploading Images?

I am using WordPress 3.4.1 on Ubuntu 12.04 using Apache and PHP 5.3.X When I login to the dashboard and add a new post. Then try uploading an image to set as a featured image, I get a red box with a ...
0
votes
2answers
906 views

categories on attachment page

I am using this function to display categories specified to a post having gallery on the image attachment page. <p>CATEGORY: <?php the_category(', '); ?></p> The problem is that ...
10
votes
5answers
2k views

Minimum Dimensions Requirement for Featured Image?

I am creating a baseball website with multiple Authors. From past experience, no matter how well you know someone personally, it doesn't mean they will follow or even read your instructions. That ...
7
votes
2answers
9k views

WordPress 3.5: Setting custom “full URL path to files” in the Media Library?

As the recent changes in WordPress 3.5 removed the "full URL path to files" option from media library I am wondering how to set this option to a custom path now? I need to set my "full URL path to ...
5
votes
2answers
872 views

Wordpress Media Manager 3.5 - default link to

Media Manager once again. This time I'm looking for a simple hack/hook/filter to change default "Attachment Display Settings" from media manager. The option is "Link To" that is default set to "Media ...
3
votes
3answers
3k views

Add new “Insert Into Post” button with another function

Problem: Add a hook that automatically adds a short tag to video attachments when inserted from the Media Library (video) tab: Update: This works under the 'Media Library' tab — and doesn't break ...
5
votes
2answers
475 views

Delete Associated Media Upon Page Deletion

Note Use at your own risk, it is buggy and I have run across a couple instances where it would delete ALL attachments. Unsure why. Is it possible to delete media associated with a page when that ...
22
votes
4answers
4k views

Add a menu item to Wordpress 3.5 Media Manager

How can add a new menu item underneath the "insert From URL" on the left sidebar in the new Wordpress 3.5 Media Manager? I've been looking at the backbone js and tried my hand at hooking into it with ...
2
votes
1answer
6k views

Restricting access to files within a specific folder [duplicate]

Possible Duplicate: How to Protect Uploads, if User is not Logged In? Is there any way at all to restrict direct access to files within a specific folder to only specific wordpress users ...
10
votes
4answers
2k views

Unwanted media library URLs in posts?

When doing a bit of Google searching for content on our blog, I noticed to my shock and horror that individual images from the Media Library are somehow generating their own URLs that Google is ...
5
votes
5answers
4k views

Upload images to remote server

I am using Wordpress media uploader to upload images and I was wondering if there is a way to make it upload to my remote server instead of my local server? Example: My wordpress blog is hosted on ...
6
votes
1answer
599 views

Disable Media Uploads to non Admin Users

I am working on a clients site, one of the features they want is for his Editors or Authors to only be able to select existing images to insert into Posts from the Media Library. So looking at the ...
4
votes
1answer
2k views

How to call WP3.5 Media Library manager?

In the past Media Library window could be called like this: tb_show("Upload image", "media-upload.php?type=image&TB_iframe=1&width=640&height=520"); This still works in WP3.5. But I'm ...
3
votes
2answers
407 views

Add Image Dimensions to Media Library Tab on Media Upoader

I would like to add the dimensions of each image to the media library tab in the media uploader. I have a multi-author website, where I require users to add a featured image with minimum dimensions. ...
3
votes
2answers
886 views

How to force Media manager to overwrite files of same name?

I have a widget that works with my theme that expects images named in a certain way, slide1.png, slide2.png, etc... However, when the user uploads their own images, named slide1.png, slide2.png, etc ...
1
vote
1answer
2k views

Gel all image from certain post type

I've found similar questions here, however I can't modify the answers to get images only from a certain post type - as the post type in those examples are "attachment" and not the name of a custom ...
1
vote
1answer
1k views

Image picker widget

I want to create a custom widget so the user can select 2 images from the media library via a dropdown box and display them in a sidebar. So I need the widget to display 2 drop downs, which each show ...
3
votes
2answers
1k views

How can I list URLs of all audio files within my media gallery?

I have a music player in my theme that generates its playlist from a javascript file that looks like this var myPlaylist = [ { mp3:'track url goes here', title:'title here', ...
1
vote
1answer
440 views

Inserting a Download Link in the Quick Edit Actions of the Media Library?

What's the best way of doing this: On The 'Media Library' page, I would like a link next to 'View' (the 'View' that appears when you hover over a Media item) for 'Download'. The 'Download' hyperlink ...
1
vote
2answers
4k views

Plugging into the Media Library to upload images (NOT associated with any post)

My Old Question: I made a Theme with rotating banner, common thing. So I want a way for users to select images. I think instead of implementing my own upload, I think its better to allow ...
1
vote
1answer
526 views

How to Removing fields from the Media Uploader/Gallery on a Custom Post Type Edit Page

This post shows how to remove unwanted fields from the media uploader. It works great, but I want to limit it to a custom-post-type and I can't seem to figure out how to do it. I've tried the ...
7
votes
2answers
2k views

Give users a maximum upload capacity; limit the number of files a user can upload OR limit the number of files per upload

I'm using the Media Library on the front end of my website and I'd like to stop users from being able to spam my server by uploading an unlimited number of files. As such, I'd like to do one or maybe ...
5
votes
4answers
2k views

How to hide media uploads by other users in the Media menu?

Simply put - how might I completely hide media files uploaded by any other users other then themselves? Id like to disable access to these links & files since they are a way for non-admin users to ...
4
votes
1answer
2k views

Changing the media library default tab

› Moderator Notice ‹ This question exists as it fills a specific criterion and/or has historical significance. The current answers do not work for current WordPress versions. If you got a ...
3
votes
2answers
2k views

Media library to list images only user uploaded

I want to list images for only user uploaded image. Here is the scenario: Using the image uploader on front end using iframe. I have added upload_files cap to subscriber level users and want them ...
3
votes
3answers
1k views

Uploading Images to Media Library via wp_handle_sideload() fails

My basic scenario is the following: I have a directory on my server that gets filled with images via ftp every once in a while. I would want to move these images to the wp upload directory and then ...
2
votes
2answers
2k views

How can I hide media library images from general users?

As an admin I really like the features and functionality of the WordPress 3.5 media manager. With a multi-user site however all users can see all images in the media library - whether uploaded by ...
0
votes
1answer
1k views

Restrict file uploads by extension?

Is there a way in WordPress 3.1 to restrict allowed file uploads by extension (images only) and file size? Bonus question: Can I limit users to only be able view files they have uploaded themselves?
2
votes
2answers
3k views

How do I add media to a custom post type?

I want to add some custom fields to allow a user to select items from the Media library for the custom post (in the add/edit view) Is there a way to do this?
0
votes
4answers
2k views

Get the attachment URL on single.php

i've been trying to get the attachment URL on single.php, so far this code gets the DIRECT LINK to the image; <?php if ( $attachments = get_children( array( 'post_type' => 'attachment', ...
0
votes
2answers
2k views

How do I remove the entire Media section from the main WordPress navigation without just hiding it?

I would like to remove the entire "Media" section from the main WordPress admin navigation ont he left hand side. What I don't want to do is just "hide" it with CSS or a plugin/function like I have ...
0
votes
3answers
3k views

How can I stop WP media uploader from creating duplicates of my uploaded images?

I have a setting in my theme that seeks to prevent the WP media manager upload utility from creating multiple copies of each image I upload. Apparently the latest versions of WP have changed the ...
5
votes
3answers
2k views

sortable custom column in media library

trying to make a custom column sortable in the media library. Found lots of examples for posts, and users but can't get them to work on the media library page. function wpse_hook_isv_columns() { ...
2
votes
1answer
374 views

Is there a way to delete images from the Media Library programatically?

I did a custom user profile page for wordpress that lets you update your profile including uploading your custom avatar and save that photo to the Media Library. Is there a way for the a specific ...
2
votes
2answers
628 views

Making the Add Media Link URL into a checkbox

Hopefully it's OK asking a second question pretty much directly after the first one... I'm currently having some difficulties accomplishing this: I've been able to remove the 'Attachment Post URL' ...
1
vote
3answers
2k views

Add new media uploader at frontend for wp 3.5+

I create a form for user to submit content from the frontend. The only problem is I don't know how to handler the image upload. So, I want to know how to use the WP media uploader in the frontend. ...
1
vote
4answers
1k views

Media Library page super slow, loading up full quality images

On my WP site (which sells retail products), I have large images (up to 4000x4000 px) so people can zoom in. Unfortunately, when adding images to a page and using the Media Library, the images all ...
1
vote
2answers
407 views

Media Content disapeared after upgrade WP core to 3.5.1

my Media -->Library content disappeared from the dashboard, but I still can see it inside my actual site folder. Could anyone instruct me how to fix it? Thank You
1
vote
2answers
1k views

Add size in Gallery Settings in Media Library

I would like to add the size in the Gallery Settings in the Add Media. I know to add the in the front-end by editing the media.php. However, when I added the the lines in gallery.dev.js, they don't ...
5
votes
1answer
163 views

print_media_templates not applied in media manager plugin

I'm trying to build a media library where users can choose pictures that are being retrieved from custom folders, which they can specify the basefolder of. I am getting the correct images back, but ...
5
votes
3answers
619 views

Separate Media Library for each user

I'm creating a theme for a client and one of their requests is to allow users to upload images for their own use, but there may be an option to share the images. Here are some of the caveats: Each ...
5
votes
1answer
322 views

Limit Media Library to Given Folder

I have made a plugin that uses the Media Library to allow users to upload files to a specific directory - using the upload_dir filter. I would like to know if there is a way (i.e. a filter) I can use ...
3
votes
1answer
282 views

Filter by post category in Media Library

I am trying to find a way to filter the Media Library by the Post Category that a Media item is assigned with. I can see that you can sort by "attached to" but this only get me a little of the way ...
3
votes
1answer
204 views

Wordpress 3.5 Media Manager - Reorder Selectbox items on Media Library Tab [duplicate]

The new media library is awesome but its a bit inefficient. When the page loads, it puts ALL MEDIA ITEMS as the default view. Which causes the page to load a LOT of images. I'd like it to default to ...