the file placed in the child theme is not included

You want to replace bimber_capture_entry_featured_media in your child theme. In the theme.php file you’ve given us you can see that this is only called in one place, from bimber_render_entry_featured_media, and the call is wrapped in a filter: if ( apply_filters( ‘bimber_render_entry_featured_media’, true, $args ) ) { echo bimber_capture_entry_featured_media( $args ); } where returning false from … Read more

Changing the comments link produced by the get_comments_link() and get_comments_pagenum_link() functions

So the solution to the get_comments_pagenum_link() function is straightforward enough: add_filter(‘get_comments_pagenum_link’ , ‘new_get_comments_pagenum_link’); function new_get_comments_pagenum_link($content) { $content = str_ireplace(‘#comments’ , ‘#other’, $content); return $content; } Which filters the output of get_comments_pagenum_link() to replace #content with #other, or any other string you might choose. For the get_comments_link() function, which can’t be filtered, I have simply discovered … Read more

Nonce generated 0-12 hours ago

WordPress nonces are not your usually (‘use only once’) nonce. For a given $action, a new nonce is generated at every 12 hours and a nonces are valid for 24 hours, so at any given point there are two nonces valid for a given $action. The nonce is (a substring of) a hash of $action … Read more

Current user in plugin returns NULL

Wait for the action plugins_loaded before you create the class instance. The pluggable functions are loaded at this time. From wp-settings.php: /** * Fires once activated plugins have loaded. * * Pluggable functions are also available at this point in the loading order. * * @since 1.5.0 */ do_action( ‘plugins_loaded’ ); I would even wait … Read more

Do I have to override the wp_mail() pluggable function with writing a plugin?

Yes you need to use a plugin. Point is that pluggables are between hard and impossible to control. You can read through this thread on wp-hackers about the actual problems and why you shouldn’t use them. Important: Note: pluggable.php loads before the ‘plugins_loaded’ hook. This means that you need the “MU-plugins” (Must use) hook: mu_plugins_loaded … Read more

WordPress how to override function adjacent_posts_rel_link_wp_head() in link-template.php the correct way

adjacent_posts_rel_link() calls get_adjacent_post_rel_link(), which runs its return value through the {$adjacent}_post_rel_link filter. The dynamic portion of the hook name, $adjacent, refers to the type of adjacency, ‘next’ or ‘previous’. You can use that filter to change the output accordingly. Here’s an example to change the second parameter: add_filter( ‘next_post_rel_link’, function( $link ) { return get_adjaxent_post_rel_link( … Read more

What is the criteria for pluggable functions?

Pluggable functions are less elastic than filters/actions. You can have only one pluggable function “active” – so only one plugin can override the core function. And you don’t have much control over which plugin will it be (WP will use the pluggable function that gets defined first). So it won’t be very useful if all … Read more

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)