Skip to content

Instantly share code, notes, and snippets.

View nickrouty's full-sized avatar

Nick Routsong nickrouty

  • Routy Development LLC
  • Arizona
View GitHub Profile
/*
* From css-tricks.com
* http://css-tricks.com/snippets/css/media-queries-for-standard-devices/
*/
/* Smartphones (portrait and landscape) ----------- */
@media only screen
and (min-device-width : 320px)
and (max-device-width : 480px) {
/* Styles */
@nickrouty
nickrouty / gist:52269b159bd283710830
Last active August 29, 2015 14:02
Install PHP IMAP Extension for OSX Mavericks
#!/bin/bash
BUILDDIR=/tmp/php_imap_mavericks
mkdir "$BUILDDIR"
echo " "
echo "= FETCHING AND INSTALLING IMAP"
echo " "
cd "$BUILDDIR"
wget -c ftp://ftp.cac.washington.edu/imap/imap-2007f.tar.gz
rm -rf imap-2007f
@nickrouty
nickrouty / gist:5580174
Created May 14, 2013 22:26
Starting up with Marionette
$(function(){
window.AFA = {};
AFA.Models = {};
AFA.Collections = {};
AFA.Views = {};
AFA.Models.User = Backbone.Model.extend({
initialize: function(){
var devices = new AFA.Collections.Devices(this.get('devices'));
@nickrouty
nickrouty / Send HTML Email in PHP
Created May 6, 2013 16:35
Send HTML Email in PHP
$to = 'mail@example.com';
$from = 'you@example.com';
$reply_to = 'you@example.com';
$subject = 'Website Change Reqest';
$headers = "From: " . strip_tags($from) . "\r\n";
$headers .= "Reply-To: ". strip_tags($reply_to) . "\r\n";
$headers .= "CC: " . strip_tags($from) . "\r\n";
$headers .= "MIME-Version: 1.0\r\n";
$headers .= "Content-Type: text/html; charset=ISO-8859-1\r\n";