Problem with wp_enqueue_scripts in plugin

Because calc_script is inside your class, it’s not publicly available like a regular function. So, change your enqueue call to this: add_action( ‘wp_enqueue_scripts’, array( $this , ‘calc_script’ ) ); And make calc_script() public. Edit: Your add_action() is in the class as well, it needs to be in another function, preferably one hooked to the init … Read more

wordpress.org codebase

You can try out the api.wordpress.org. Take for example the secret MP6 plugin: http://api.wordpress.org/plugins/info/1.0/mp6.xml The current version is given by: <version type=”string”> <![CDATA[ 0.8 ]]> </version> and it looks like the previous versions are listed in the compatibility tag: <compatibility type=”array”> <array key=”3.4.1″> <array key=”1.0.0″> <integer>100</integer> <integer>1</integer> <integer>1</integer> </array> <array key=”1.0.1″> <integer>100</integer> <integer>1</integer> <integer>1</integer> </array> … Read more

How to disable lightbox popup for “add a review” only?

Here’s a hack you can use. Update: As Andrew Bartel mentioned below. It’s best to copy the template files into your theme so that they override the default woo commerce template files. In your woocommerce plugin folder, look for a file called product-reviews.php woocommerce/templates/single-product-reviews.php Look for a line that says <div id=”review_form_wrapper”> Either remove the … Read more

Override WooCommerce page-specific js in my theme

It’s common to find theme that you can’t simply override certain file by mirroring the file structure in your child theme. In this case the cart.min.js is most likely included via wp_queue_script so you gotta find the handle of the script by looking at the source code of WooCommerce (just search by wp_enqueue_script). Then you … Read more