Questions tagged [pluggable]

The tag has no usage guidance.

15 questions with no upvoted or accepted answers
Filter by
Sorted by
Tagged with
1
vote
0answers
404 views

How to override Woocommerce functionality in Reports section?

I need to customize the Reports in WooCommerce, so I have to edit the core file class-wc-report-sales-by-date.php, such file doesn't use any hook. Check: https://github.com/woocommerce/woocommerce/...
1
vote
0answers
3k views

Extend plugin Class through functions.php

Move manual fix applied to plugin source code to theme functions.php or as Code Snippet I've applied a manual fix to a plugin file. I'd like to make this fix more accessible and scalable by hooking ...
1
vote
0answers
196 views

Replace part of a parent-theme customizer in the child-theme

I'm created a child-theme of the OnePress theme and would like to update a part of the inc/customizer.php function. Specifically, the theme customizer adds the following control: $wp_customize->...
1
vote
0answers
439 views

Override default new user registration email with custom message (non sub-domain multi-site installation)

My problem is as follows. I have a multisite running on a non-sub-domain install. I am trying to customise the welcome email a user receives upon registration. I managed to customise the welcome ...
0
votes
0answers
8 views

Pluggable function vs apply_filter for performance

There's a pluggable function and there are filter hooks inside the function. if( ! function_exists('function_name')) { ... apply_filters('hook_name', 'callback funtion'); ... } Which is better ...
0
votes
0answers
28 views

I have an fatal error on my funcyions.php

can someone please help me with this Fatal error: Uncaught Error: Call to a member function main() on null in /home/customer/www/real-amnesti.com/public_html/wp-includes/functions.php:1255 I haven'...
0
votes
0answers
359 views

is_tax not working for custom taxonomy

I am trying to over-ride a custom taxonomy file from my plugin. Actually, I have 2 custom taxonomies: destination & activities. I have successfully over-ridden the taxonomy template for activities ...
0
votes
2answers
570 views

How to override get_avatar() function?

I need for a specific plugin to override the wordpress function get_avatar() to bind the profile image to an other image with some condition. How can I do this ? Is there a specific hook or filter to ...
0
votes
1answer
32 views

Wordpress reading old version of functions.php, breaks site

I added a function to the child theme functions.php to check if a plugin class exists. The code was something like function check_class_exists() { if (class_exists('classname')) { echo "...
0
votes
0answers
541 views

Pluggable Function wp_new_user_notification exists too early

I have recently updated from 4.1 to 4.4 directly and I can't override wp_new_user_notification anymore. Obviously the function should not exist when the plugins are loaded. I wrote a mu-plugin with ...
0
votes
0answers
553 views

Integrate WP Tiles into existing loop (index.php) and theme

I want to integrate WP Tiles directly into our Wordpress theme and into our existing loop but their documentation is pretty thin and I can't find much in the way of examples so not really sure how to ...
0
votes
1answer
205 views

save_post hook - headers already sent?

I'm trying to create a very simple alert for each time a post is created or updated with the below... add_action( 'save_post', 'updatedAlert' ); function updatedAlert() { echo '<script>alert("...
0
votes
1answer
80 views

pluggable function in theme, to be overridden by plugin

Is it possible to add a function in functions.php like this: // ACF if ( !function_exists('get_field') ) { function get_field() { return false; } } and then let ...
0
votes
1answer
331 views

Repeated headers in wp_mail

I am passing a custom header multiple times, for tagging reasons, to wp_mail(), but only the last instance of the header is actually getting sent. It appears that wp_mail() is filtering the custom ...
-1
votes
1answer
428 views

How to execute init or woocommerce_init only for checkout page

I am making extra function for my own project. function devsol_customer_login() { if ( is_checkout() ) { ?> <form method="post"> <input type="text" class="woocommerce-Input ...