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 | |
// Custom WordPress Admin Color Scheme | |
function admin_css() { | |
wp_enqueue_style( 'admin_css', get_template_directory_uri() . '/css/admin.css' ); | |
} | |
add_action('admin_print_styles', 'admin_css' ); | |
?> |
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 | |
$mycontent = $post->post_content; // wordpress users only | |
$word = str_word_count(strip_tags($mycontent)); | |
$m = floor($word / 200); | |
$s = floor($word % 200 / (200 / 60)); | |
$est = $m . ' minute' . ($m == 1 ? '' : 's') . ', ' . $s . ' second' . ($s == 1 ? '' : 's'); | |
?> | |
<p>Estimated reading time: <?php echo $est; ?></p> |
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 | |
function add_jquery_ui() { | |
wp_enqueue_script( 'jquery-ui-core' ); | |
wp_enqueue_script( 'jquery-ui-widget' ); | |
wp_enqueue_script( 'jquery-ui-mouse' ); | |
wp_enqueue_script( 'jquery-ui-accordion' ); | |
wp_enqueue_script( 'jquery-ui-autocomplete' ); | |
wp_enqueue_script( 'jquery-ui-slider' ); | |
wp_enqueue_script( 'jquery-ui-tabs' ); | |
wp_enqueue_script( 'jquery-ui-sortable' ); |
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 | |
/** | |
* Load Enqueued Scripts in the Footer | |
* | |
* Automatically move JavaScript code to page footer, speeding up page loading time. | |
*/ | |
function footer_enqueue_scripts() { | |
remove_action('wp_head', 'wp_print_scripts'); | |
remove_action('wp_head', 'wp_print_head_scripts', 9); | |
remove_action('wp_head', 'wp_enqueue_scripts', 1); |
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
d |
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
$(function(){ | |
new VpsCalculator({ | |
element: $('.calculator'), | |
order: $('.order-send'), | |
orderSuccess: $('.order-success') | |
}); | |
}); |
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
include ../../node_modules/bemto.jade/bemto |
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
// Reset | |
// ========================================================================== | |
// Reset default styles. | |
* // @stylint ignore | |
margin 0 | |
padding 0 | |
font inherit | |
-webkit-box-sizing border-box |
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
// Mixins. | |
$helvetica = 'Helvetica', Helvetica Neue, Arial, sans-serif; | |
$helvetica-bold = 'Helvetica Bold', Helvetica Neue, Arial, sans-serif; | |
$helvetica-light = 'Helvetica Light', Helvetica Neue, Arial, sans-serif; | |
$calibri = 'Calibri', Candara, Segoe, Segoe UI, Optima, Arial, sans-serif; | |
placeholder() | |
if selector() == "&" | |
error( "placeholder() must be called from a ruleset!" ) |
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
set-font-size(value) { | |
font-size: value; /* add PX (or original value) as backup */ | |
if (value is inherit) { | |
/* do nothing, "inherit" has no unit */ | |
} else { | |
font-size: remify(value); | |
} | |
} |