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 () { | |
var bxSliderInstances = {}; | |
// Use a class rather than an ID | |
var $slider = $('.mini-slider'); | |
// For each result | |
$slider.each(function (index, element) { |
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 class="gallery-container"> | |
<div id="gallery" class="gallery-images"> | |
<img src="http://placehold.it/500" alt="" /> | |
<img src="http://placehold.it/500" alt="" /> | |
<img src="http://placehold.it/500" alt="" /> | |
<img src="http://placehold.it/500" alt="" /> | |
<img src="http://placehold.it/500" alt="" /> | |
</div> | |
<div class="gallery-thumbs-container"> | |
<ul id="gallery-thumbs" class="gallery-thumbs-list"> |
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
// Return true if it is a multiple | |
function multiple(int, multipleOf) { | |
var remainder = int % multipleOf; | |
if (remainder === 0) { | |
return true; | |
} else { | |
return false; | |
} | |
} |
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 action=""> | |
<fieldset class="error"> | |
<div class="form-row"> | |
<span class="error-hook"> | |
Please enter a valid email address | |
</span> | |
<div class="input-hook"> | |
<label for="email-address" class="placeholder"> | |
Email address | |
</label> |
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
/** | |
Requires: | |
Spin.js (http://fgnass.github.com/spin.js/) | |
Spin.js jQuery plugin (https://gist.github.com/1290439) | |
Usage: $(#your-id).spinSubmit(); | |
For best results, change the 'small' to - small:{lines:12,length:3,width:2,radius:4} in the jQuery plugin |
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 { | |
/* Consult http://gridulator.com for viable grids */ | |
@totalColumns: 12; | |
@siteWidth: 960px; | |
@margin: 10px; | |
.container() { | |
margin-left: auto; | |
margin-right: auto; |
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 wmode() { | |
// For each iFrame | |
$('iframe').each(function () { | |
// Store some variables | |
var $this = $(this), | |
src = $this.attr('src'), | |
query; |
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 you wonder why filter:alpha(opacity=20); sometimes does nothing, | |
* Read http://joseph.randomnetworks.com/2006/08/16/css-opacity-in-internet-explorer-ie/ | |
* Use the function below to detect if an element has layout & to apply it dynamically if not | |
*/ | |
function hasLayout(selector) { | |
$(selector).each(function (index, element) { | |
if (element.currentStyle.hasLayout === false) { | |
$(element).css({ |
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.fullHeight = function( offset ){ | |
// Check if offset specified | |
if (offset === '') { | |
// If it's not then set it to 0 | |
offset = 0; | |
} | |
// Maintain chainability |