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
var wrap = $('.content'); | |
var col1 = $('.content .primary'); | |
var col2 = $('.content .sidebar'); | |
if (col1.height() < wrap.height()){ | |
col1.css('height', wrap.height()+'px'); | |
} | |
if (col2.height() < wrap.height()){ | |
col2.css('height', wrap.height()+'px'); |
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
@mixin md($case){ | |
.#{$case} &{ | |
@content; | |
} | |
} | |
@mixin the-bg($trans: 1){ | |
background: url(assets/img/pixel-#{$trans}.png) repeat; | |
background: rgba(black, ($trans/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
$(function() { | |
var browser, classList, os, platform, retina; | |
retina = window.devicePixelRatio > 1 ? "retina" : "no-retina"; | |
platform = window.navigator.userAgent; | |
if (/Chrome/.test(platform)) { | |
browser = "chrome"; | |
} else if (/Firefox/.test(platform)) { | |
browser = "firefox"; | |
} else { | |
browser = "unknown-browser"; |
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
// Uploading files | |
var file_frame; | |
jQuery('.upload_image_button').live('click', function( event ){ | |
event.preventDefault(); | |
// If the media frame already exists, reopen it. | |
if ( file_frame ) { | |
file_frame.open(); |
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
zip -r foo.zip foo -x "*.DS_Store" | |
To interpret this, we are running the zip executable with the following parameters/arguments: | |
-r for recursively including all directories underneath the targets we want to zip. | |
foo.zip is the name of the zip archive we are creating | |
foo is the target directory we want to zip up | |
-x "*.DS_Store" excludes all files whose path ends in the string ".DS_Store" |
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 is_sidebar_active( $index = 1){ | |
$sidebars = wp_get_sidebars_widgets(); | |
$count = count($sidebars['sidebar-'.$index]); | |
if($count === 0){ | |
return false; | |
}else{ | |
return 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
<?php | |
// OUTPUT CUSTOM CSS FILE | |
function stag_link_custom_styles(){ | |
$output = ''; | |
if(apply_filters('stag_custom_styles', $output)){ | |
$perma_structure = get_option('permalink_structure'); | |
$url = home_url(). '/stag-custom-styles.css?'.time(); | |
if(!$perma_structure) $url = home_url(). '?page_id=stag-custom-styles.css'; | |
echo '<link rel="stylesheet" href="'.$url.'" type="text/css" media="screen" />'; |
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
{ | |
"bold_folder_labels": true, | |
"color_scheme": "Packages/Theme - Spacegray/base16-ocean.dark.tmTheme", | |
"ensure_newline_at_eof_on_save": true, | |
"file_exclude_patterns": | |
[ | |
"*.DS_Store", | |
"*.git", | |
"*.sass-cache" | |
], |
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
Alerts | |
====== | |
[stag_alert style="white"]Your Alert![/stag_alert] | |
Styles: white, grey, red, yellow, green, blue | |
Buttons | |
======= |
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
// Clearfix | |
%clearfix { | |
zoom: 1; | |
&:before, | |
&:after { | |
display: table; | |
content: ""; | |
} | |
&:after { | |
clear: both; |