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
jQuery.extend({ | |
random: function(X) { | |
return Math.floor(X * (Math.random() % 1)); | |
}, | |
randomBetween: function(MinV, MaxV) { | |
return MinV + jQuery.random(MaxV - MinV + 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
<!DOCTYPE html> | |
<html lang="en" class="no-js"> | |
<head> | |
<meta charset="utf-8"> | |
<title></title> | |
<link rel="stylesheet" href="css/style.css"> | |
<style type="text/css" media="screen"> | |
.cell {display: inline-block; background: #FCF7CA; padding: 10px; position: absolute; font: bold 16px Helvetica, Arial, sans-serif;} | |
.w-1 {width: 80px;} | |
.w-2 {width: 160px;} |
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
/* Grid */ | |
.row, div[class*='span-'] { float: left; } | |
.row { | |
clear: both; | |
width: 100%; | |
} | |
[class*='span-'] { |
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
if ($('#no-results').length) { | |
var term = $('#search-results').find('li:first a.only-this-tag').text(); | |
if ($("#search-results").find('li').length == 1) { | |
$.track('ProductSearch', 'ZeroResults', term); | |
} | |
} | |
if ($("#zip-code-search").length) { | |
$("#zip-code-search").bind("submit", function(e) { | |
var zipcode = $('#zip_code').val(); |
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
<!DOCTYPE html> | |
<html> | |
<head> | |
<title>Experimental data stuff</title> | |
<style> | |
* {margin: 0; padding: 0; color: rgba(0,0,0,1);} | |
body { font-size: 62.5%; line-height: 1.7;} | |
article {margin: 12px auto; border: 1px solid #ccc; width: 470px; padding: 20px 40px;} | |
.initialized {background: rgba(255,255,0, 0.2);} |
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
$.fn.TouchClass = function(className, options) { | |
var settings = { stick: false }; | |
if (options) $.extend(settings, options); | |
if (typeof(className) == 'undefined') { | |
var className = 'active'; | |
} | |
var downEvent = (window.Touch) ? 'touchstart' : 'mousedown', | |
upEvent = (window.Touch) ? 'touchend' : 'mouseup'; | |
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 geoLocate() | |
{ | |
navigator.geolocation.getCurrentPosition(foundLocation, noLocation); | |
} | |
function foundLocation(position) | |
{ | |
var lat = position.coords.latitude; | |
var long = position.coords.longitude; | |
window.location="/locations/geo/" + lat + "," + long; |
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
// <h3>Join Our Mailing List</h3> | |
// | |
// <div id="theForm"> | |
// <form action="http://inmunited.createsend.com/t/r/s/tdfly/" method="post" id="subForm"> | |
// <input type="text" class="text" name="cm-tdfly-tdfly" placeholder="Email Address" id="tdfly-tdfly" /> | |
// <input type="submit" class="submit" value="GO" /> | |
// </form> | |
// </div> | |
// <div id="confirmation"> | |
// Thanks for subscribing! |
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
jQuery( | |
function($) { | |
$.easing.myEaseOut = function (x, t, b, c, d) { | |
return c*((t=t/d-1)*t*t*t*t + 1) + 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
// Inspired by the King of the Kurbs! | |
// $.trace('Woooo!'); | |
$.extend({ | |
trace: function(msg){ | |
if (window.console) { | |
console.log(msg); | |
}; | |
} | |
}); |
NewerOlder