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 track = function (args) { | |
args = args || {}; | |
var category = args.category, | |
action = args.action, | |
label = args.label, | |
value = args.value || null; | |
if (_gaq) { | |
_gaq.push(['_trackEvent', category, action, label, value]); |
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
fireAJAXRequest = function(method, url, async, callback) { | |
var httpRequest, | |
start= new Date().getTime(), | |
end; | |
if (window.XMLHttpRequest) { | |
httpRequest = new XMLHttpRequest(); | |
} else if (window.ActiveXObject) { | |
// Internet Explorer is stupid | |
httpRequest = new ActiveXObject("Microsoft.XMLHTTP"); |
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 SDM = SDM || {}; | |
SDM.track = function (args) { | |
args = args || {}; | |
var category = args.category, | |
action = args.action, | |
label = args.label, | |
value = args.value || null; |
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
function eliminateDuplicates(arr) { | |
var i, | |
len=arr.length, | |
out=[], | |
obj={}; | |
for (i=0;i<len;i++) { | |
obj[arr[i]]=0; | |
} | |
for (i in obj) { |
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 NS = NS || {}; | |
/* | |
requires | |
- underscore js | |
- external event subscriber | |
- external AJAX Hanlder | |
*/ | |
NS.infiniteScroll = function (target,callback) { |
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
/* | |
* Requires : underscore.js | |
uploader = file[type=text] | |
output = output element | |
E.G | |
uploader = document.getElementById("file_url"), | |
output = document.getElementById('preview_image'), | |
valid : |
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
/* | |
requires : | |
underscore js | |
event subscriber | |
*/ | |
inView = function (element) { | |
var self = this, | |
type, |
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 textPreview = function (el) { | |
var self = this, | |
input, | |
output, | |
initialise = function() { | |
input = el.querySelector('input') || el.querySelector('textarea'), | |
target = el.getAttribute('data-textPreview-output-element'), |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
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 listItems = $('.project_list > li') | |
$(window).bind('resize',function() { | |
var ww = $(window).width(); | |
listItems.each(function() { | |
$(this).width(ww); | |
}); | |
}); |