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 wp_rocket_deactivate_inline_css_minify( $html_options ) { | |
unset( $html_options['cssMinifier'] ); | |
return $html_options; | |
} |
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 wp_rocket_activate_inline_js_minify( $html_options ) { | |
$html_options['jsMinifier'] = 'rocket_minify_inline_js'; | |
return $html_options; | |
} | |
add_filter( 'rocket_minify_html_options', 'wp_rocket_activate_inline_js_minify' ); |
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 | |
defined( 'ABSPATH' ) or die( 'Cheatin\' uh?' ); | |
/* | |
Plugin Name: Enforce Trailing Slash on URLs | |
Author: Jonathan (WP Rocket Team) | |
Author URI: http://wp-rocket.me | |
*/ | |
add_filter( 'before_rocket_htaccess_rules', '__force_trailing_slash' ); | |
function __force_trailing_slash( $marker ) { |
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
/** | |
* This code should be added to functions.php of your theme | |
**/ | |
//This changes the "From:" price on the products page to a Rent-Buy value instead. | |
// ***** It ALSO checks to see if the product is on sale, and displays the sale price instead of the top variable price | |
add_filter('woocommerce_variable_price_html', 'custom_variation_price', 10, 2); | |
function custom_variation_price( $price, $product ) { | |
$price = ''; |
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( 'rocket_cache_reject_ua', 'wprocket_remove_fb_ua' ); | |
function wprocket_remove_fb_ua( $ua ) { | |
if ( in_array( 'facebookexternalhit', $ua ) ) { | |
$ua = array_flip( $ua ); | |
unset( $ua[ 'facebookexternalhit' ] ); | |
$ua = array_flip( $ua ); | |
} | |
return $ua; | |
} |
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
/* | |
Copyright 2017 Bryan Keller (https://github.com/widget-) | |
Licensed under the Apache License, Version 2.0 (the "License"); | |
you may not use this file except in compliance with the License. | |
You may obtain a copy of the License at | |
http://www.apache.org/licenses/LICENSE-2.0 | |
Unless required by applicable law or agreed to in writing, software |
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 | |
/** | |
* Custom Category Template | |
* | |
* @package my_child_theme | |
* @since 1.0.0 | |
* @author Travis Smith <t@wpsmith.net> | |
* @copyright Copyright (c) 2013, Travis Smith | |
* @license http://opensource.org/licenses/gpl-2.0.php GNU Public License | |
* @link https://gist.github.com/wpsmith/5062834 |
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
@import url('https://fonts.googleapis.com/css?family=Lato:400,700,900&display=swap'); | |
body { | |
font-family: 'Lato', sans-serif !important; | |
text-rendering: optimizeLegibility !important; | |
word-spacing: -1px; | |
-webkit-font-smoothing: auto; | |
} | |
.CodeMirror-cursor { | |
border-left-color: rgba(255,255,255,1) !important; | |
} |
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
/* | |
URL: http://www.crucialwebhost.com/blog/master-stylesheet-the-most-useful-css-technique/ | |
One of the most common mistakes I see beginners and intermediates fall victim to when it comes to CSS is not removing the default browser styling. This leads to inconsistencies in the appearance of your design across browsers, and ultimately leaves a lot of designers blaming the browser. It is a misplaced blame, of course. Before you do anything else when coding a website, you should reset the styling. | |
*/ | |
/***** Global Settings *****/ | |
html, body { |