Tag Info

Hot answers tagged

3

You need to enqueue the scripts as well, not only register them. You can, however, just simply enqueue a script without registering it if you are not going to enqueue it conditionally. I would try something like this: (Untested and requires PHP5.4+) add_action( 'wp_enqueue_scripts', enqueue_scripts, 11 ); function enqueue_scripts() { /** * Build ...


2

This should work: add_action( 'woocommerce_init', 'remove_wcpgsk_email_order_table' ); function remove_wcpgsk_email_order_table() { global $wcpgsk; remove_action( 'woocommerce_email_after_order_table', array( $wcpgsk, 'wcpgsk_email_after_order_table' ) ); }


1

If your plugin is registered like this: class Test_Class_Parent { function __construct() { add_action('wp_head',array($this,'test_method')); } function test_method() { echo 'Echoed from the parent'; } } $p = new Test_Class_Parent(); Then you should be able to remove the filter by accessing the global: class Test_Class_Child extends ...


1

to have the good path to the file, try this : $array = file(plugin_dir_path(__FILE__) . "quotes.txt");


1

Yes, there is a filter for this. The correct filter is wp_mail and is defined in /wp-includes/pluggable.php Line 135 So the code (maybe in your functions.php) should look something like this: function mail_template($args){ ob_start(); require_once (get_template_directory() . '/mail-templates/contacemail.php'); $args['message'] = ...


1

You have two options here In a child theme, dequeue and deregister the scripts and style you are not going to need. Just remember to hook your function to wp_enqueue_scripts with a lower priority (higher number) Use the twentyfifteen as a base to a new theme. I have successfully used bundled themes in the past to create new, selfstanding themes. That is ...


1

You can use the following functions: time (); return The time by seconds date(); y- Year m- Month d- Day h- Hours i- Minute s- Second for ex: date("Y-m-d H:i:s");



Only top voted, non community-wiki answers of a minimum length are eligible