How to Add Custom CSS to the Media Thickbox?

In WordPress 3.5, this hook works for me: add_action( ‘print_media_templates’, ‘wpse_75746_print_style_35’ ); function wpse_75746_print_style_35() { ?> <style> .media-modal-content, .media-sidebar { background: #FFF2D4 !important; } </style> <?php } In 3.4.2, this is the one: add_action( ‘admin_print_styles-media-upload-popup’, ‘wpse_75746_print_style_342’ ); function wpse_75746_print_style_342() { ?> <style> #media-upload { background: #FFF2D4 !important; } </style> <?php }

How to filter out an iframe from feed

One potential option is to use preg_replace to do a regex match on your content and replace the iframe with empty space. So this function: function rss_noiframe($content) { $content = preg_replace( ‘/<iframe(.*)\/iframe>/is’, ”, $content ); return $content; } add_filter(‘the_excerpt_rss’, ‘rss_noiframe’); add_filter(‘the_content_feed’, ‘rss_noiframe’); Should automatically convert any instances of <iframe src=…>…</iframe> to a blank.

Allow editors to post iframes [duplicate]

try the iframe shortcode plugin http://wordpress.org/extend/plugins/iframe/ Embed iframe using shortcode [iframe src=”http://player.vimeo.com/video/819138″ width=”100%” height=”480″] ps: you can also use the default oembed shortcode: it supports YouTube, Vimeo, DailyMotion, Flickr, Twitter, … and more. Example: Screenshot: See more here: http://codex.wordpress.org/Embeds

get_the_category_list open in parent window

get_the_category_list runs it output through the filter the_category. You could hook in there and change whatever you like. Something like this should work (untested): <?php add_filter(‘the_category’, ‘wpse90955_the_category’); function wpse90955_the_category($cat_list) { return str_ireplace(‘<a’, ‘<a target=”_parent”‘, $cat_list); } If you just need to have that list filter in certain spots, you can define the function above in … Read more

Iframe a WordPress template

Well, it can’t and won’t work. You should think how iframe really works. All it does is send a request to server with given URL (src parameter) and display response. Why inserting <?php bloginfo(‘template_directory’); ?>/training-form.php as src wouldn’t work? Just go to this address and see, what you’ll get. Nothing or some trash. Why? Because … Read more

echo same menu items across multi-site platform

Sorry this should be a comment –> you should be able to use a switch to blog http://codex.wordpress.org/Function_Reference/switch_to_blog This will allow you to grab the main blog ID, from there you can use a WP list pages or a http://codex.wordpress.org/Function_Reference/wp_nav_menu to display the menu of your main site on the other blogs within the network

Responsive Video Max-width

So, apparently, I needed to read a little bit more before I posted my question. After I posted the question, I ran across: https://moodle.org/mod/forum/discuss.php?d=258650, which is what I incorporated into the code I was using. I modified my function to look like: function video_embed( $html ) { return ‘<div class=”video-container”><div class=”video-wrap”>’ . $html . ‘</div></div>’; … Read more