Gravatar image url is wrong?

As the filename suggests, it’s a default for when someone does not have a gravatar assigned. It is set up in your child theme and looks to be improperly set. You should search through the child theme files to find ‘wpb-default-gravatar.png’ and from there figure out what is adding the extra domain. If this is … Read more

Add editor toolbar to Metabox

I need to add a custom toolbar (cf. image below) to this Metaboxes Do you want to add a custom TinyMCE toolbar to the TinyMCE/visual editor, or do you want to turn a textarea into a TinyMCE editor? If it is the latter one, here’s a sample code for turning the champ_home textarea into a … Read more

Output votes to div dynamically in wordpress

[EDIT] Provided better replacements. Try this: In template.php, replace: echo ‘<div id=”vote_counter”>’. $votes.'</div><br>’; ..with: echo ‘<div id=”vote_counter-‘ . $post->ID . ‘” class=”vote_counter”>’. $votes.'</div><br>’; In voteme.js, replace: jQuery(“#vote_counter”).html(response.vote_count); ..with: jQuery(“#vote_counter-” + post_id).html(response.vote_count); You should also declare post_id and nonce as local variables; i.e.: var post_id = $(this).attr(“data-post_id”), nonce = $(this).attr(“data-nonce”); Hope that helps.

Some menu items wont budge

The admin bar is hooked incorrectly.It should be hooked to wp_before_admin_bar_render. This is what I use (and works): function alter_admin_bar() { global $wp_admin_bar; $wp_admin_bar->remove_menu( ‘customize’ ); $wp_admin_bar->remove_menu( ‘ddw-gravityforms-toolbar’ ); $wp_admin_bar->remove_menu( ‘members-new-role’ ); $wp_admin_bar->remove_menu( ‘new-media’ ); $wp_admin_bar->remove_menu( ‘new-post’ ); $wp_admin_bar->remove_menu( ‘new-user’ ); $wp_admin_bar->remove_menu( ‘wp-logo’ ); } add_action( ‘wp_before_admin_bar_render’, ‘alter_admin_bar’ ); Regarding the side menu I don’t … Read more

Custom query vars filters problem with pagination

The problem is the pagination parameter in the URL: <a href=”https://wordpress.stackexchange.com/questions/298648/<?php echo (in_array($marca_term->slug, $marca_arg)) ? esc_url(remove_query_arg(“marca’)) : esc_url(add_query_arg(‘marca’, “$marca_term->slug”)); ?>”> Here we see that the marca term is being added and removed, but the pagination parameter isn’t, but that’s a part of the URL not a parameter Instead, why not use the taxonomy archives and … Read more