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 | |
$video_ID = 'your-video-ID'; | |
$JSON = file_get_contents("https://gdata.youtube.com/feeds/api/videos/{$video_ID}?v=2&alt=json"); | |
$JSON_Data = json_decode($JSON); | |
$views = $JSON_Data->{'entry'}->{'yt$statistics'}->{'viewCount'}; | |
echo $views; | |
?> |
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
.icon(@filename, @bgcolor: transparent, @bgsize: contain) { | |
.text-hide; | |
background: @bgcolor url('icon-@{filename}.png') no-repeat center center; | |
background: @bgcolor url('icon-@{filename}.svg') no-repeat center center; | |
background-size: @bgsize; | |
display: inline-block; | |
} | |
.svgbg(@filename, @bgsize: contain) { | |
background: url('@{filename}.png') no-repeat center center; |
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
{ | |
"color_scheme": "Packages/Theme - Spacegray/base16-ocean.dark.tmTheme", | |
"font_face": "Source Code Pro", | |
"font_size": 10, | |
"ignored_packages": | |
[ | |
"Vintage" | |
], | |
"spacegray_sidebar_tree_small": true, | |
"folder_exclude_patterns": [".svn", ".git", ".hg", "CVS", ".sass-cache"], |
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
addItem: function(variant_id, quantity, callback) { | |
var quantity = quantity || 1; | |
var params = { | |
type: 'POST', | |
url: '/cart/add.js', | |
data: 'quantity=' + quantity + '&id=' + variant_id + "&properties[foo]=fizzbuzz", | |
dataType: 'json', | |
success: function(line_item) {}, | |
error: function(xhr, status) {} | |
}; |
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
.icon(@filename, @color: transparent, @background-size: contain) { | |
background: @color url('../img/@{filename}.png') no-repeat center center; | |
background: @color url('../img/@{filename}.svg') no-repeat center center; | |
background-size: @background-size; | |
display: block; | |
margin: 0 auto; | |
overflow: hidden; | |
text-indent: 100%; | |
white-space: nowrap; | |
} |
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
// Bootstrap pagination | |
function bootstrap_pagination($pages = '', $range = 2) { | |
$showitems = ($range * 2)+1; | |
global $paged; | |
if(empty($paged)) $paged = 1; | |
if($pages == '') { | |
global $wp_query; | |
$pages = $wp_query->max_num_pages; |
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
<a href="#" class="button" data-reveal-id="myModal2">Click Me For A Modal</a> |
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
<div id="myModal" class="reveal-modal [expand, xlarge, large, medium, small]"> | |
<h2>Awesome. I have it.</h2> | |
<p class="lead">Your couch. It is mine.</p> | |
<p>Im a cool paragraph that lives inside of an even cooler modal. Wins</p> | |
<a class="close-reveal-modal">×</a> | |
</div> |
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
<form class="custom"> | |
<!-- Custom Radio --> | |
<div class="row"> | |
<div class="four columns"> | |
<label for="radio1"><input name="radio1" type="radio" id="radio1" style="display:none;"><span class="custom radio"></span> Radio Button 1</label> | |
<label for="radio2"><input name="radio1" type="radio" id="radio2" style="display:none;"><span class="custom radio checked"></span> Radio Button 2</label> | |
<label for="radio3"><input name="radio1" type="radio" id="radio3" disabled style="display:none;"><span class="custom radio"></span> Radio Button 3</label> | |
</div> | |
<div class="four columns"> |
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
<a href="#" class="large secondary button radius">Back</a> | |
<a href="" class="medium secondary button radius">Scan</a> | |
<a href="" class="small secondary button radius">Skip »</a> |