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 user = { | |
validateCredentials: function (username, password) { | |
return ( | |
(!(username += '') || username === '') ? { error: "No Username Given.", field: 'name' } | |
: (!(username += '') || password === '') ? { error: "No Password Given.", field: 'pass' } | |
: (username.length < 3) ? { error: "Username is less than 3 Characters.", field: 'name' } | |
: (password.length < 4) ? { error: "Password is less than 4 Characters.", field: 'pass' } | |
: (!/^([a-z0-9-_]+)$/i.test(username)) ? { error: "Username contains invalid characters.", field: 'name' } | |
: false | |
); |
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(){var NPETS=3,MAXLEN=100,INTERVAL=100,POS_PROP='background-position',KARMA_POS='-0px -0px',DIS_POS='-55px -0px',$name=$('span.redditname a'),$img=$('#header-img'),initialName=$name.text(),initialAttrib=$img.parent().attr('title');$name.text('pet me please');$img.css(POS_PROP,DIS_POS);$img.parent().removeAttr('title');$img.mouseenter(function(){var buf=[];window.petkarmaint=setInterval(function(){var nmin=0,nmax=0,i=1,indownstroke=true,happy;buf.push(window.petkarmay);while(i<buf.length-1){if(buf[i-1]>buf[i]&&buf[i+1]>=buf[i]){nmin+=1;indownstroke=true;};if(buf[i-1]<buf[i]&&buf[i+1]<=buf[i]){nmax+=1;indownstroke=false;};i+=1;};if(nmin>=NPETS-1){window.petkarmahappy=true;$name.text('HAPPY! coded by btown_brony, vectors by Pinkie_Pi');$img.css(POS_PROP,KARMA_POS);};if(nmin<NPETS-1){window.petkarmahappy=false;$name.text(indownstroke?'pet':'...');$img.css(POS_PROP,DIS_POS);};},INTERVAL);}).mousemove(function(e){window.petkarmay=e.pageY;}).mouseleave(function(){if(window.petkarmaint){clearInterval(window. |
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
From 8a69546552b12261cc40dcfca96fb4d235e7ca0e Mon Sep 17 00:00:00 2001 | |
From: Brenton Partridge <bapartridge@gmail.com> | |
Date: Tue, 30 Aug 2011 21:43:04 -0700 | |
Subject: [PATCH] Changed interface for ADVANsCEne to compile on OS X | |
--- | |
src/NDSSystem.cpp | 2 +- | |
src/mc.cpp | 2 +- | |
src/mc.h | 2 +- | |
3 files changed, 3 insertions(+), 3 deletions(-) |
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
From 8a69546552b12261cc40dcfca96fb4d235e7ca0e Mon Sep 17 00:00:00 2001 | |
From: Brenton Partridge <bapartridge@gmail.com> | |
Date: Tue, 30 Aug 2011 21:43:04 -0700 | |
Subject: [PATCH] Changed interface for ADVANsCEne to compile on OS X | |
--- | |
src/NDSSystem.cpp | 2 +- | |
src/mc.cpp | 2 +- | |
src/mc.h | 2 +- | |
3 files changed, 3 insertions(+), 3 deletions(-) |
NewerOlder