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
.ir { | |
border: 0; | |
font: 0/0 a; | |
text-shadow: none; | |
color: transparent; | |
background-color: transparent; | |
} |
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
$(document).ready(function() { | |
TABLE.fixHeader('table') | |
}); | |
var TABLE = {}; | |
TABLE.fixHeader = function(table) { | |
$(table).each(function() { | |
var $table = $(this); | |
var $thead = $table.find('thead'); |
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
$(document).ready(function() { | |
TABLE.repeatHeader('#celebs', 10) | |
}); | |
var TABLE = {}; | |
TABLE.repeatHeader = function(table, every){ | |
$(table).each(function() { | |
var $this = $(this); | |
var rowsLen = $this.find('tr:not(:first)').length; |
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
$("#test_form").delegate("input:not([id*='_submit']), select", "blur", function(e) { | |
// Does something | |
}); |
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
// http://stackoverflow.com/questions/12042260/how-to-use-the-javascript-module-pattern-in-a-real-example | |
var myApp = (function() { | |
var someElement = $("#foo"); //some element I know I'll use lots | |
var addMessage = function(message) { | |
$.ajax({ | |
url: '/test', | |
type: 'POST', |
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
{ | |
"glossary": { | |
"title": "example glossary ABC", | |
"GlossDiv": { | |
"title": "S", | |
"GlossList": { | |
"GlossEntry": { | |
"ID": "SGML", | |
"SortAs": "SGML", | |
"GlossTerm": "Standard Generalized Markup Language", |
OlderNewer