Manipulating Media uploader

Ok. Going to try and explain this as best as I can, so bare with me. Anyway, I’m trying to include the default media uploader as a part of my plugin. Currently, I’ve successfully managed to use the filter attachment_fields_to_edit to hide most of the input fields, leaving only the title & alternate text fields, … Read more

how to use thickbox in admin?

I would like to show my retrieved content form my classes method in thickbox. How could I do this? I have been adding the proper id to my desired hyperlink but all of the admin body is getting parsed inside of the thickbox. <a href=”https://wordpress.stackexchange.com/questions/76358/?page=blahblah&TB_iframe=true&width=600&height=550″ class=”thickbox”>Click</a> class myAdmin { public function __construct() { } public … Read more

ThickBox width can’t be changed in admin

I’m trying to make pop up in admin area (in post edit screen) and i can’t make my thickbox wider then 670px (width: 670px). Here’s my thickbox code that shows thickbox: tb_show( ed.getLang(‘m7.popup_title’), ‘#TB_inline?width=800&height=600&inlineId=mygallery-form’ ); (it works after clicking the tinyMCE button) and i get div with id=”TB_window” <div id=”TB_window” style=”width: 670px; height: 216px; margin-left: … Read more

Thickbox hacking – removing fields

Default (big and ugly) Thickbox I don’t like how this Thickbox’s page looks at all, I almost never use all these settings fields so decided to get rid off them, at least on pages where I’m uploading images as theme options. A (very) simple Thickbox Using attachment_fields_to_edit & media_upload_tabs filters I made it look much … Read more

Is there a hook to put stylesheet and/or JS inside iframes (thickbox or tinyMCE) in admin area

I’m working on my admin area theme and I wanted to make some modifications on the way the thickbox and tinyMCE looks. I could make most of the changes through adding custom stylesheets and JS to my admin area using wp_enqueue_script() and wp_enqueue_style(), but I have had a hard time making some others changes. This … Read more

Using the WordPress Media Library and returning the Attachment ID rather than URL?

I’m currently using some JS to pop open the WordPress Media Library in a thickbox container and return the URL of a selected image, then display it. window.send_to_editor = function(html) { imgurl = jQuery(‘img’,html).attr(‘src’); jQuery(‘#upload_image-‘ + id_to_pass).val(imgurl); output_code=”<img class=”media_display” src=”” + imgurl + ‘” />’; jQuery(output_code).appendTo(‘#media_display-‘ + id_to_pass); tb_remove(); } I was wondering if it’s … Read more