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
// Based on Chris' post here: https://gist.github.com/3828790 | |
@mixin respond-to($size) { | |
// Small | |
@if $size == "small" { | |
@media only screen and (min-width: 320px) { | |
@content; | |
} |
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
@include handhelds { | |
table.responsive { | |
width: 100%; | |
thead { | |
display: none; | |
} | |
tr { | |
display: block; | |
} | |
td, th { |
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
<figure> | |
<?php | |
$image = get_field('your_image_field_name'); | |
$atts = array( | |
'imageid' => $image, | |
'size1' => '0', | |
'size2' =>'600', | |
'size3' =>'1000' | |
); | |
echo tevkori_responsive_shortcode($atts) ; ?> |
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 data = new FormData(); | |
form.find("input, textarea").each(function() { | |
var input = $(this); | |
if (input.attr("type") == "file") | |
data.append(input.attr("name"), input[0].files[0]); | |
else | |
data.append(input.attr("name"), input.val()); | |
}); | |
$.ajax({ |
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 rkv_url_spamcheck( $approved , $commentdata ) { | |
$author_url = $commentdata['comment_author_url']; | |
$author_url_length = strlen($author_url); | |
if ($author_url_length > 50 ) | |
$approved = 'spam'; |
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
// the old way :/ | |
$.ajax({ | |
url: "http://codepen.io/chriscoyier/pen/b2ad8b9a336845dd7b11d4bed34f4256.html", | |
complete: function(resp) { | |
// This HTML needs to be there first | |
$("body").append(resp.responseText); | |
// Because this script is going to do something with it. |
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
/*! normalize.css v1.0.0 | MIT License | git.io/normalize */ | |
/* | |
* usage: | |
* @import "normalize"; | |
* | |
* // this will print out ALL selectors | |
* @include normalize(); | |
* | |
* // this will print out minimal set (*) -- you can see the list of "excluded" tags below |
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 rkv_url_spamcheck( $approved , $commentdata ) { | |
$author_url = $commentdata['comment_author_url']; | |
$author_url_length = strlen($author_url); | |
if ($author_url_length > 50 ) | |
$approved = 'spam'; |
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
#!/usr/bin/env ruby | |
require 'tempfile' | |
require 'fileutils' | |
# Signals | |
trap("SIGINT") { exit } | |
# Setup | |
TARGET_FOLDER = ARGV[0] | |
TARGET_URL = ARGV[1] |