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 schtickm = $("header"), pos = schtickm.offset(); | |
$(window).scroll(function() { | |
if($(this).scrollTop() > (pos.top + 10) && | |
schtickm.css('position') == 'static') { schtickm.addClass('fixed'); } | |
else if($(this).scrollTop() <= pos.top && |
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 activeToggle ($theDiv) { | |
var divTop = $theDiv.offset().top - windowTop; | |
if (divTop > cutoffTop && divTop < cutoffBottom ) { | |
$theDiv.addClass('active'); | |
} | |
else { | |
$theDiv.removeClass('active'); | |
} |
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 firstlocationli = $('.location li:first').position(); | |
$('.location li').click(function(){ | |
$(this).addClass('selected'); | |
$(this).siblings('li').removeClass('selected'); | |
$(".locations").hide(); | |
$(".locations#" + $(this).attr("id") + "_list").show(); | |
var position = $(this).position(); |
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
{% if object.file.url %} | |
<a href="{{ object.file.url }}" onclick="_gaq.push(['_trackEvent', 'File Downloads', 'Downloaded', '{{ object.file }}']);"> | |
{% if object.title %} | |
{{ object.title|safe }} | |
{% else %} | |
<img src="{% file_icon object %}" alt="Download File" /> | |
{% endif %} | |
</a> | |
{% endif %} |
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
The root password is gone. Shut off mySQL, restart, and set new password: | |
sudo /usr/local/mysql/support-files/mysql.server stop | |
sudo /usr/local/mysql/bin/mysqld_safe --skip-grant-tables | |
mysql | |
>>>> UPDATE mysql.user SET Password=PASSWORD('new easy and memorable pw') WHERE User='root'; | |
Create new one if needed: | |
mysql -u projectuser -p | |
mysql | |
>>>> create database projectdb; |
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
<!-- link --> | |
<a href="/article.html" class="triggerModal" > | |
<!-- modal --> | |
<div id="modal" class="modal fade modal-dialog" tabindex="-1" role="dialog" aria-labelledby="yourMom" aria-hidden="true"> | |
<div class="container"> | |
<button type="button" class="close" data-dismiss="modal" aria-hidden="true"></button> | |
<div class="row"> | |
<div id="response_modal"></div> | |
</div> |
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
$(document).ready(function() { | |
$("a[href$='pdf']").click(function(event){ | |
var href = $(this).attr('href'); | |
_gaq.push(['_trackEvent', 'Downloads', 'File Downloaded', href]); | |
setTimeout(function() { window.location.href = href; }, 500 ); | |
return 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
YUI().use('node', 'event', function (Y) { // use squarespace's preloaded YUI instead of loading jQuery just to make a popup. add this to the footer of your page in a snippet. | |
var videoLink = ''; // link your links to their videos in the content. | |
var top = pageYOffset; | |
var body = Y.one('body'); | |
var obj; | |
var doClose = function(e) { | |
e.preventDefault(); | |
var videoContent = document.getElementById('videoContent'); | |
videoContent.parentNode.removeChild(videoContent); | |
Y.one('body').removeClass('sqs-lightbox-open'); |
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() { | |
$('.downzy-btn').click(function() { | |
var mp3 = { | |
prefix: "data:audio/mp3;base64,", | |
sound: [ | |
"SUQzAwAAAAALClRJVDIAAABkAAAAAAAAAGQgRWZmZWN0cyAtIENvbWVkeS9DYXJ0b29uIEZBUlQgV0lUSCBHT09EIEVORElORzogU3RhcnRzIGJpZyBhbmQgbG91ZCwgZW5kcyB3aXRoIGEgYmFzaWMgJ3BycnQnVFBFMQAAADQAAABEb3dubG9hZCBTb3VuZCBFZmZlY3RzIC0gU291bmREb2dzIC0gQmpvcm4gTHlubmUgRlhUQUxCAAAAGQAAAGh0dHA6Ly93d3cuU291bmRkb2dzLmNvbVRSQ0sAAAACAAAAMFRZRVIAAAAFAAAAMjAwN1RDT04AAAAcAAAAU0ZYIC0gQ2FydG9vbnM7IEh1bWFucyBGYXJ0Q09NTQAAAC8AAABlbmcAUm95YWx0eSBGcmVlIFNvdW5kIEVmZmVjdHMgLSBTb3VuZGRvZ3MuY29tVENPTQAAAAEAAABXWFhYAAAAGgAAAABodHRwOi8vd3d3LlNvdW5kZG9ncy5jb21URU5DAAAAAQAAAFRDT1AAAAAsAAAAKGMpIDIwMTAgU291bmRkb2dzLmNvbSwgQWxsIFJpZ2h0cyBSZXNlcnZlZFRPUEUAAAABAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA |
OlderNewer