Skip to content

Instantly share code, notes, and snippets.

View davegreenwp's full-sized avatar
⌨️

Dave Green davegreenwp

⌨️
  • IconicWP (@iconicwp)
  • Manchester, UK
  • 20:13 (UTC +01:00)
View GitHub Profile
@davegreenwp
davegreenwp / class-wc-shipping-test-method.php
Last active April 30, 2023 11:11 — forked from mikejolley/gist:3b37b9cc19a774665f31
Example instance based shipping method
<?php
/**
* Example of a custom WC_Shipping_Method class.
*/
if ( ! defined( 'ABSPATH' ) ) {
exit;
}
/**
@davegreenwp
davegreenwp / product_configurator_300_dpi.php
Last active November 25, 2022 10:35
Product Configurator - 300 DPI image output
<?php // DO NOT INCLUDE THIS LINE!
// Replace the generate_image function in class-ajax.php with this modified function.
/**
* Generate final image.
*/
public static function generate_image() {
global $jckpc;
$params = self::ajax_img_get_params();