WP_Query – meta fields numeric

Maybe I’m wrong but you are missing query relation… <?php $args = array( ‘post_type’ => ‘mls’, ‘meta_query’ => array( relation => ‘AND’, array( ‘key’ => ‘_city’, ‘value’ => ‘Clarkson’, ‘compare’ => ‘=’ ), array( ‘key’ => ‘_price’, ‘value’ => ‘200000’, ‘type’ => ‘numeric’, ‘compare’ => ‘>=’ ) //array( // ‘key’ => ‘_price’, // ‘value’ => … Read more

How to change the CSS in one file?

This completely depends on your skill-level and what theme you’re using. Let’s take the Twenty Eleven Theme for example (default in current WP version). If you look at the source of the homepage, you’ll see the body element has the following: <body class=”home blog two-column right-sidebar highlander-enabled highlander-light infinite-scroll”> That is a bunch of classes … Read more

How do I change TinyMCE button “i” to create a i tag rather than em? [duplicate]

Here’s a simple function that will replace <em> with <i> on your post/page: function replace_em_with_i($content) { $content = str_replace(‘<em>’, ‘<i>’, $content); $content = str_replace(‘</em>’, ‘</i>’, $content); return $content; } add_filter(‘the_content’, ‘replace_em_with_i’); Warning: I have tested the code to check if it works (and it does work), but you might want to do some serious testing … Read more