Advanced WordPress SQL Query

In WP, you rarely need to “write SQL queries”, unless you work with custom tables, instead use its API… WP_User_Query will join for you all meta data attached to each user and return to you plain user objects, so why not use it instead? Also, see get_user_meta()…

make an array in wordpress cusmization api?

So there’s 2 Customizer specific hooks depends on what exactly you’re trying to do. The customize_controls_enqueue_scripts is exactly like wp_enqueue_scripts but it enqueues in the control panel ( left side ) frame. I suggest requiring customize-controls scripts to make sure your script has access to them: function theme_customizer_control_scripts() { wp_enqueue_script( ‘scirpt-slug’, $scirpt_url, array( ‘jquery’, ‘customize-controls’ … Read more

Vertical Menu for one page only

You’ll want to search your theme files for the part of the page template that is controlling those classes, likely page.php would be a good place to start. Then once you find the part you think is controlling the output, try adding: if( is_page(24331) ) { echo ‘vertical-header’; } For example: <div id=”page” class=”layout-fullwidth <?php … Read more

Displaying 3 Category Posts differently

Possible you’ve forgotten to reset post with wp_reset_postdata function. You can use get_posts instead of new WP_Query: <?php foreach(get_posts($args) as $post) : ?> <div class=”post”> <a class=”post-link” href=”https://wordpress.stackexchange.com/questions/277736/<?= get_permalink($post->ID) ?>” target=”_blank”><?= $post->post_title; ?></a> </div> <?php endforeach; ?>

How to add text before posts

Ok, you are using shamrock theme. To add the desirable header you can insert in header.php right after tag following code: <?php if(is_frontpage()) : ?> <div class=”head-title”> <p class=”about-me”>your text</p> </div> <?php endif; ?> Please, note, that if you want to get updates your theme, you should create child wordpress theme with custom header.php file