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 Pinterest Javascript to your website, see https://gist.github.com/Willem-Siebe/11351787. | |
function wsis_add_pinterest_script() { | |
?> | |
<script type="text/javascript"> | |
(function(d){ | |
var f = d.getElementsByTagName('SCRIPT')[0], p = d.createElement('SCRIPT'); | |
p.type = 'text/javascript'; | |
p.async = true; | |
p.setAttribute('data-pin-hover', true); |
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
# The ideal Robots.txt for your WordPress website, see https://gist.github.com/Willem-Siebe/11368429. | |
User-Agent: * | |
Disallow: /wp-content/plugins/ |
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
// Don't load the WPML Language selector CSS, see https://gist.github.com/Willem-Siebe/751d2a2a9cedf6036256. | |
define('ICL_DONT_LOAD_LANGUAGE_SELECTOR_CSS', true); |
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
// Remove WooCommerce breadcrumbs, see https://gist.github.com/Willem-Siebe/65d59638d503682fa67a. | |
remove_action( 'woocommerce_before_main_content','woocommerce_breadcrumb', 20, 0); |
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
// WooCommerce theme integration, see https://gist.github.com/Willem-Siebe/9cd10326c07f5e3e8076. | |
/** | |
* woocommerce_before_main_content hook | |
* | |
* @hooked woocommerce_output_content_wrapper - 10 (outputs opening divs for the content) | |
* @hooked woocommerce_breadcrumb - 20 | |
*/ | |
remove_action( 'woocommerce_before_main_content', 'woocommerce_output_content_wrapper', 10 ); |
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_filter( 'woocommerce_billing_fields', 'custom_woocommerce_billing_fields' ); | |
function custom_woocommerce_billing_fields( $fields ) { | |
// Over-ride a single label | |
$fields['billing_first_name']['label'] = 'Your label'; | |
// Over-ride a single required value | |
$fields['billing_first_name']['required'] = false; |
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
// Change the UL for WooCommerce product loop start and end if your are not using a list, but for example Twitter Bootstrap. See https://gist.github.com/Willem-Siebe/2f2f64012b9cfe36df1a. | |
function woocommerce_product_loop_start() { | |
echo '<div class="wsis-wc-product-loop">'; | |
} | |
function woocommerce_product_loop_end() { | |
echo '</div>'; | |
} |
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
// Register LESS stylesheet using the WP LESS plugin, see https://gist.github.com/Willem-Siebe/e7800869c3517d85614c. | |
function wsis_enqueue_styles() { | |
wp_enqueue_style('style-less', get_stylesheet_directory_uri().'/less/style.less'); | |
} | |
add_action('wp_enqueue_scripts', 'wsis_enqueue_styles'); |
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 Font Awesome to your LESS stylesheet, see https://gist.github.com/Willem-Siebe/dc6c94aa7dd17c54e9fd. | |
@import "../font-awesome/less/font-awesome.less"; | |
@import "font-awesome/variables.less"; |
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
// Variables | |
// -------------------------- | |
// Overwriting @FontAwesomePath using our own variables.less, see https://gist.github.com/Willem-Siebe/e9eeca9db432e1a9ab50. | |
@FontAwesomePath: "../font-awesome/font/"; |
OlderNewer