This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** Robin, you can add these lines to your child theme's functions.php file | |
* If you're NOT using a child theme, please copy / paste this link | |
* https://github.com/woothemes/theme-customisations/archive/master.zip | |
* and use that plugin to make custimizations like this one to your theme | |
* Best wishes Robin | |
**/ | |
add_filter ('woocommerce_add_to_cart_redirect', 'woo_redirect_to_checkout'); | |
function woo_redirect_to_checkout() { | |
$checkout_url = WC()->cart->get_checkout_url(); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
Uploading images is a two step process (from https://github.com/WP-API/WP-API/issues/1768#issuecomment-160540932): | |
POST the data to /wp/v2/media - this can either be as the request body, or in multipart format. This will upload the file, and give you a 201 Created response with a Location header. This header points to the post object for the attachment that has just been created. | |
PUT the post data to the endpoint returned in the Location header (which will look something like /wp/v2/media/{id}). | |
I do step 2 (PUT), if POST is a success, in myDropzone.on("success", function(file, response){} | |
*/ | |
// dropzoneWordpressRestApiForm is the configuration for the element that has an id attribute |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* Plugin Name: Phil Kills of Admin Ajax via a Plugin | |
* Plugin URI: https://yourmom.com | |
* Description: A Drop In Plugin That'll kill off admin-ajax.php. No options, just ACTIVE or INCACTIVE :-) | |
* Version: 1 | |
* Author: Brad | |
* Author URI: https://yourmom.com | |
* Requires at least: 4.5 | |
* Tested up to: 4.5 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* Plugin Name: Christopher's Plugin | |
* Description: Pucker, Pray, and hope that I didn't miss anything. Should make prev & next stay within the same category! *SHOULD* ;-) | |
* Version: 1.0.0 | |
* Author: Brad Griffin | |
* Author URI: https://bradgriffin.me | |
*/ | |
/** Christopher: Download this file, then upload it via FTP into your /plugins folder. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
*Reduce the strength requirement on the woocommerce password. | |
* | |
* Strength Settings | |
* 3 = Strong (default) | |
* 2 = Medium | |
* 1 = Weak | |
* 0 = Very Weak / Anything | |
*/ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/****************************************************************************** | |
* Variation Grid | |
* | |
* The following function allow for the theme to display product variations in a grid format. | |
* This code could be moved to a plugin but is in the theme function file as it used the | |
* themes grid system. | |
* | |
* @reference: http://www.eggplantstudios.ca/woocommerce-product-variation-add-cart-grid/ | |
* ******************************************************************************/ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
add_filter( 'woocommerce_get_order_item_totals', 'adjust_woocommerce_get_order_item_totals' ); | |
function adjust_woocommerce_get_order_item_totals( $totals ) { | |
unset($totals['cart_subtotal'] ); | |
return $totals; | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
$affiliate_id = affwp_get_affiliate_id(); | |
$user_email = affwp_get_affiliate_email( $affiliate_id ); | |
$payment_email = affwp_get_affiliate_payment_email( $affiliate_id, $user_email ); // Fallback to user_email | |
?> | |
<div id="affwp-affiliate-dashboard-profile" class="affwp-tab-content"> | |
<h4><?php _e( 'Profile Settings', 'affiliate-wp' ); ?></h4> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* Checkout terms and conditions checkbox | |
* | |
* @author WooThemes | |
* @package WooCommerce/Templates | |
* @version 2.5.0 | |
*/ | |
if ( ! defined( 'ABSPATH' ) ) { | |
exit; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/* | |
* Plugin Name: Brad Gives to Usability Dynamics | |
* Plugin URI: https://bradgriffin.me | |
* Description: Look at your pageflow. After a user adds anything Invoice related to my cart, redirect the user to another Invoice related product. Same concept with the Property products. Almost immediately, you're total per transaction amount will go up #whoop! | |
* Author: Brad Griffin | |
* Author URI: https://bradgriffin.me | |
* Version: 1.0 | |
* License: GPL 2.0 | |
* Text Domain: woocommerce |