Skip to content

Instantly share code, notes, and snippets.

Keybase proof

I hereby claim:

  • I am maadhattah on github.
  • I am jamesdigioia (https://keybase.io/jamesdigioia) on keybase.
  • I have a public key ASCG7vUNizwEP8YhbG9NQtJtNt4kMip4Rd6XMrkUoUgeDgo

To claim this, I am signing this object:

<!DOCTYPE html>
<html>
<head>
<title>Page Title</title>
</head>
<body>
<button id="up">Up</button>
<button id="down">Down</button>
<button id="left">Left</button>
<button id="right">Right</button>
<!DOCTYPE html>
<html>
<head>
<title>jQuery Fun House Starter Code</title>
</head>
<body>
<div class="section" id="gallery">
<h1>Pictures of elephants</h1>
<img class="gallery-thumb" id="pic1" src="https://upload.wikimedia.org/wikipedia/commons/f/f9/Loxodonta_africana_-_old_bull_(Ngorongoro,_2009).jpg">
<img class="gallery-thumb" id="pic2" src="https://upload.wikimedia.org/wikipedia/commons/6/63/African_elephant_warning_raised_trunk.jpg">
<!DOCTYPE html>
<html>
<head>
<title>Movies and Shows</title>
</head>
<body>
<h1>Amazing Movies and TV Shows Ever!</h1>
<ol>
<li>Finding Dory</li>
<li>Game of Thrones</li>
@mAAdhaTTah
mAAdhaTTah / add-redirect-args.php
Created November 19, 2015 02:15
Using Redirect Args to Display Errors
if ($error) {
    add_filter('redirect_post_location', function( $location ) use ( $error ) {
        return add_query_arg( 'my-plugin-error', $error->get_error_message(), $location );
    });
}
@mAAdhaTTah
mAAdhaTTah / admin-notice-hook.php
Created November 19, 2015 01:23
save_post Error Reporting Boilerplate
add_action( 'admin_notices', 'my_error_messages' );
@mAAdhaTTah
mAAdhaTTah / provision-osx.sh
Last active June 6, 2016 23:43
OS X Provisioning Script
gem install kitchenplan
kitchenplan setup
kitchenplan provision
gem install homesick
homesick clone https://github.com/mAAdhaTTah/dotfiles
homesick link dotfiles
git clone pianosa:~/.settings/ # The address is for my home server
mackup restore
@mAAdhaTTah
mAAdhaTTah / fb-debugger.php
Created September 27, 2015 05:55
Facebook Post Debugger
<?php
/*
Plugin Name: Facebook Post Debugger
Version: 0.1
Plugin URI: http://jamesdigioia.com/
Description: This plugin runs the bit.ly shortlink through the Facebook debugger upon publishing.
Author: James DiGioia
Author URI: http://www.jamesdigioia.com/
*/
@mAAdhaTTah
mAAdhaTTah / improved-boot.php
Last active March 23, 2021 11:37
A Better WordPress Singleton
call_user_func(array(new PluginClass(__FILE__), 'boot'));
@mAAdhaTTah
mAAdhaTTah / test
Last active August 29, 2015 14:23
var http = require('http');
var _ = require('lodash');
// An HTTP server for an quick EventEmitter example. Works just like a socket.
var server = http.createServer(function(req, res) {
console.log('Reqest incoming...');
});
// This will not cause an error since partial is invoked after socket gets passed into the function.
server.on('connection', function(socket) {