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
/** | |
* WordPress WYSIWYG Editor Styles | |
* | |
* Some nice SCSS styles. Fixes the alignment left/right issues when using them in the editor. | |
* There's a load of more 'defaults' over at http://digwp.com/2010/05/default-wordpress-css-styles-hooks/ | |
* which is where this was original 'borrowed' from. Cheers Jeff Starr (@perishable)! | |
* | |
* @author Kevin Ruscoe (@kevdotbadger) | |
* @link http://digwp.com/2010/05/default-wordpress-css-styles-hooks/ Original author | |
* @link https://twitter.com/perishable Twitter of original author |
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 average( $values ){ | |
return; | |
} | |
echo average(array(1, 5, 8, 34, 7, 20, 20)); | |
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
{ | |
"name": "App", | |
"version": "1", | |
"authors": [ | |
"Kevin Ruscoe <[email protected]>" | |
], | |
"moduleType": [ | |
"node" | |
], | |
"license": "MIT", |
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
// https://gist.github.com/kevdotbadger/2de20b08627ac32ebb5e | |
$flat-turquoise: #1abc9c; | |
$flat-emerland: #2ecc71; | |
$flat-peter-river: #3498db; | |
$flat-amethyst: #9b59b6; | |
$flat-wet-asphalt: #34495e; | |
$flat-green-sea: #16a085; | |
$flat-nephritis: #27ae60; | |
$flat-belize-hole: #2980b9; | |
$flat-wisteria: #8e44ad; |
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
$primary-color: $purple; | |
@function text-color($inverted: true){ | |
@if (lightness($primary-color) > 50 and $inverted == false) { | |
@return #444; | |
} @else { | |
@return #fff; | |
} | |
} |
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
@mixin respond-above( $media ) { | |
@if $media == lg { | |
@media( min-width: $screen-lg-min ) { | |
@content; | |
} | |
} | |
@else if $media == md { | |
@media( min-width: $screen-md-min ) { | |
@content; |
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
/* Begin Here */ | |
UPDATE wp_posts SET guid = replace(guid, 'http://olddomain.com','http://newdomain.com'); | |
UPDATE wp_posts SET post_content = replace(post_content, 'http://olddomain.com', 'http://newdomain.com'); | |
UPDATE wp_links SET link_url = replace(link_url, 'http://olddomain.com', 'http://newdomain.com'); | |
UPDATE wp_links SET link_image = replace(link_image, 'http://olddomain.com', 'http://newdomain.com'); | |
UPDATE wp_postmeta SET meta_value = replace(meta_value, 'http://olddomain.com', 'http://newdomain.com'); | |
UPDATE wp_usermeta SET meta_value = replace(meta_value, 'http://olddomain.com', 'http://newdomain.com'); | |
/*UPDATE wp_options SET option_value = replace(option_value, 'http://olddomain.com', 'http://newdomain.com') WHERE option_name = 'home' OR option_name = 'siteurl' OR option_name = 'widget_text' OR option_name = 'dashboard_widget_options';*/ | |
UPDATE wp_options SET option_value = replace(option_value, 'http://olddomain.com', 'http://newdomain.com'); |
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
#!/bin/sh | |
# Config for SSL. | |
echo "--- Making SSL Directory ---" | |
mkdir /etc/nginx/ssl | |
echo "--- Copying $i SSL crt and key ---" | |
openssl req -nodes -new -x509 -keyout /etc/nginx/ssl/server.key -out /etc/nginx/ssl/server.crt -subj "/C=US/ST=NY/L=NYC/O=Dis/CN=www.example.com" | |
echo "--- Turning SSL on in nginx.conf. ---" |
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
$(".select2").select2({ | |
// theme: "my-theme", | |
placeholder: function(){ | |
$(this).data('placeholder'); | |
}, | |
maximumSelectionSize: 5, | |
templateResult: function(item) { | |
if( item._resultId === undefined ){ | |
return ["Search for <b>'" + item.text + "'<b>"]; |
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 | |
/** | |
* Set's a 'do-not-track' cookie that'll expire in 10 years, used in conjunction with Google Tag Manager | |
* | |
* @return void | |
* @author Kevin Ruscoe | |
*/ | |
function setDoNotTrackCookie(){ | |
setcookie('do-not-track', 'do-not-track', strtotime( '+10 years' )); |