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 jquery selector | |
$("a[href^=#]").click(function(e) { | |
var duration = $(this).data('scroll') || 750; | |
var target = $(this).attr('href'); | |
var $el = $(target); | |
if ($el.length || target == '#') { | |
e.preventDefault(); // prevent jumping to target or adding hash in url | |
// scroll to the element | |
$('html, body').animate({ | |
scrollTop: target == '#' ? 0 : $el.offset().top |
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
#!/usr/bin/env php | |
<?php while (1) { fputs(STDOUT, "\n\-PHP$ "); eval(trim(fgets(STDIN))); } ?> |
NewerOlder