WordPress Development Weekly Newsletter
WordPress Development Weekly Newsletter

Top new questions this week:

How many times will this code run? (or, how rich is grandma?)

Hypothetical example but real world applicability (for someone learning, like me). Given this code: <?php function send_money_to_grandma() { internetofThings("send grandma","$1"); } ...

<plugin-development> <hooks>  
asked by C C 7 votes
answered by birgire 9 votes

Ignore a filter on the media library

As per my question yesterday, I need to exclude all images from most of my WordPress queries - yesterday, I thought I needed to exclude them from all queries, until I came upon the following issue. ...

<wp-query> <filters> <uploads> <media> <media-library>  
asked by BFDatabaseAdmin 3 votes
answered by Howdy_McGee 2 votes

How do I exclude all images from a wp_query?

I want to query attachments and exclude all images. I can see how to include only images, using 'post_mime_type' => 'image/*', but I couldn't find any way of achieving the opposite. Is there any ...

<wp-query> <images> <attachments>  
asked by BFDatabaseAdmin 3 votes
answered by Howdy_McGee 8 votes

Taxonomy Templates... by hierarchical level?

I'm wondering if there's a way to specify by filename different templates for different levels within a hierarchical taxonomy. I know about taxonomy-taxonomyname.php and taxonomy-taxonomyname-term.php ...

<custom-taxonomy> <templates> <template-hierarchy>  
asked by Will 3 votes
answered by gmazzap 3 votes

How to use wpLink without editor?

I would like to create theme option to add a link. Loading these scripts and triggering the dialog works fine if wp editor is present. wp_enqueue_script('wplink'); wp_enqueue_script('wpdialogs'); ...

<links> <editor>  
asked by Benn 3 votes

Is it possible to make Wordpress core (iris)colorpicker-wrapper higher instead of making colorboxes scale smaller?

I'm having an issue using wordpress core colorpicker. I'm retrieiving random number of colors from the server (that fetches colors a specific website). These colors I want to use within the ...

asked by bestprogrammerintheworld 2 votes
answered by bestprogrammerintheworld 0 votes

How can I allow user to select minimum privilege smartly

We can easily asses a user's role using current_user_can(), but it doesn't support an array of user roles but a single role. So we have to check each of the role multiple times: if( ...

asked by Abirvab 2 votes
answered by Maruti Mohanty 0 votes

Greatest hits from previous weeks:

What SQL Query to do a simple find and replace

Whenever I create a new website I first create a staging site on a subdomain like "stage.domain-name.com". After everything works correctly I export the database, open it in notepad++ and do a ...

<mysql> <query> <sql> <replace>  
asked by NetConstructor.com 11 votes
answered by Fernando Briano 9 votes

Stop WordPress automatically adding <br> tags to post content

Is there a way to stop WordPress from automatically inserting <br> tags when adding returns in the WordPress text editor. I would like for it to behave more like a code editor where I can ...

<posts> <shortcode> <content> <text>  
asked by mvaneijgen 6 votes
answered by Borek 10 votes

Can you answer this?

Inside text editor my preview gallery images are in full size

As I described in the title in the edit post page and inside the editor when I submit a new gallery the thumbnails are in full size. I suspect that this error caused when I unset the default ...

<gallery> <thumbnails>  
asked by Dimitriadis Ath 1 vote
Subscribe to more Stack Exchange newsletters

Unsubscribe from this newsletter or change your email preferences by visiting your subscriptions page on stackexchange.com.

Questions? Comments? Let us know on our feedback site. If you no longer want to receive mail from Stack Exchange, unsubscribe from all stackexchange.com emails.

Stack Exchange, Inc. 110 William St, 28th Floor, NY NY 10038 <3