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
// Simple Input Focus Clear Value | |
$(document).ready(function() { | |
$('input#name').focus(function() { | |
if ($(this).val() == 'Have an account?') { | |
$(this).val('').addClass('change-style'); | |
} | |
}); |
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
/* Clear 'dem Fields by Matthew Born */ | |
$('input[type=text]').focus(function(){ | |
if(!$(this).attr('placeholder')){ | |
if(!$(this).val()){ | |
$(this).attr('placeholder', ' '); | |
$(this).val('').addClass('active'); | |
} else { | |
$(this).attr('placeholder', $(this).val()); | |
$(this).val('').addClass('active'); | |
} |
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
/* Anchor Slide by Matthew Born */ | |
$('.slide a').click(function(){ | |
var anchor = $(this).attr('href'); | |
$('html,body').animate({scrollTop: $(anchor).offset().top},'slow'); | |
}); |
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
/* Tooltips */ | |
$('h3 a').hover(function(){ | |
if($(this).attr('title')){ | |
$(this).append($('<div class="tooltip">'+$(this).attr('title')+'</div>')); | |
} | |
}, function(){ | |
$(this).find('div').remove(); | |
}); |
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($){ | |
// Extend easing options. | |
$.extend( $.easing, { def: 'easeOutExpo', | |
easeOutExpo: function (x, t, b, c, d) { | |
return (t==d) ? b+c : c * (-Math.pow(2, -10 * t/d) + 1) + b; | |
}, | |
easeInOutExpo: function (x, t, b, c, d) { | |
if (t==0) return b; | |
if (t==d) return b+c; |
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
<?php if ( ! defined ('ABSPATH') ) die ('No direct access allowed'); ?><?php if ( ! empty ( $gallery ) ) : ?> | |
<div id="gallery"> | |
<?php foreach ( $images as $image ) : if ( ! $image->hidden ) : ?> | |
<a href="<?php echo $image->description ?>"><img alt="<?php echo $image->alttext ?>" src="<?php echo $image->imageURL ?>" /></a> | |
<?php endif; if ( $image->hidden ) continue; endforeach; ?> | |
</div><!-- #gallery --> | |
<?php endif; ?> |
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
// Add easeOutExpo easing | |
$.extend($.easing, { def: 'easeOutExpo', | |
easeOutExpo: function(x, t, b, c, d){ | |
return (t==d) ? b+c : c * (-Math.pow(2, -10 * t/d) + 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
$(window).keydown(function(e){ | |
var next = parseInt(location.pathname.split('/')[2])+1 || 2; | |
var prev = parseInt(location.pathname.split('/')[2])-1; | |
if (e.which === 39) { | |
document.location.href = ('/page/'+next); | |
} else if (e.which === 37) { | |
document.location.href = ('/page/'+prev); | |
} | |
}); |
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
define(['jquery', 'lodash', 'backbone', 'moment'], | |
function($, _, Backbone) { | |
var Router = Backbone.Router.extend({ | |
routes: { | |
'visit': 'visit', | |
'connect': 'connect', | |
'events': 'events', | |
'sermons': 'sermons', | |
'*actions': 'default' | |
} |
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
#!/bin/bash | |
apps=( Tunnelblick Calendar Evernote Hall Messages SourceTree Spotify Sublime\ Text\ 2 ) | |
for app in "${apps[@]}" | |
do | |
echo Opening "$app". | |
open /Applications/"$app".app | |
done |
OlderNewer