This file contains 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: Filter WooCommerce Orders by Payment Method | |
* Plugin URI: http://skyverge.com/ | |
* Description: Filters WooCommerce orders by the payment method used :) | |
* Author: SkyVerge | |
* Author URI: http://www.skyverge.com/ | |
* Version: 1.0.0 | |
* Text Domain: wc-filter-orders-by-payment | |
* |
This file contains 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 | |
/** | |
* start the customisation | |
*/ | |
function custom_woo_before_shop_link() { | |
add_filter('woocommerce_loop_add_to_cart_link', 'custom_woo_loop_add_to_cart_link', 10, 2); | |
add_action('woocommerce_after_shop_loop', 'custom_woo_after_shop_loop'); | |
} | |
add_action('woocommerce_before_shop_loop', 'custom_woo_before_shop_link'); |
This file contains 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
function mytheme_setup() { | |
add_theme_support('custom-logo'); | |
} | |
add_action('after_setup_theme', 'mytheme_setup'); |
This file contains 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_action('post_submitbox_misc_actions', createCustomField); | |
add_action('save_post', saveCustomField); |
This file contains 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_action( 'wp_print_scripts', 'themeprefix_remove_password_strength', 100 ); | |
// Remove password strength script | |
function themeprefix_remove_password_strength() { | |
if ( wp_script_is( 'wc-password-strength-meter', 'enqueued' ) ) { | |
wp_dequeue_script( 'wc-password-strength-meter' ); | |
} | |
} |
This file contains 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: Add Business Type Option for Business Profile | |
* Plugin URI: http://themeofthecrop.com | |
* Description: Modifies the Business Profile plugin to include a new business type option from the Schema.org collection. | |
* Version: 0.0.1 | |
* Author: Theme of the Crop | |
* Author URI: http://themeofthecrop.com | |
* License: GNU General Public License v2.0 or later | |
* License URI: http://www.gnu.org/licenses/gpl-2.0.html |
This file contains 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 //<~ don't add in | |
// Declare WooCommerce support for your theme | |
add_theme_support( 'woocommerce' ); |
This file contains 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
global $woocommerce; | |
if ( sizeof( $woocommerce->cart->cart_contents) > 0 && !is_cart() && !is_checkout() ) : | |
echo '<a href="' . $woocommerce->cart->get_checkout_url() . '" title="' . __( 'Checkout' ) . '">' . __( 'Checkout' ) . '</a>'; | |
endif; |
This file contains 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
// Use Gists to store code you would like to remember later on | |
console.log(window); // log the "window" object to the console |
This file contains 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 | |
function string_body_class($classes) { | |
if ( isset($_GET) && isset( $_GET['class'] ) ) : | |
$classes[] = sanitize_html_class( $_GET['class'] ); | |
endif; | |
return $classes; |
NewerOlder