Skip to content

Instantly share code, notes, and snippets.

View howderek's full-sized avatar

Derek Howard howderek

View GitHub Profile
# Created by Derek Howard (howderek)
#
# This is free and unencumbered software released into the public domain.
#
# Anyone is free to copy, modify, publish, use, compile, sell, or
# distribute this software, either in source code form or as a compiled
# binary, for any purpose, commercial or non-commercial, and by any
# means.
#
# In jurisdictions that recognize copyright laws, the author or authors
@howderek
howderek / stasis.sh
Created July 28, 2016 14:55
Find command to recursively search a directory, execute PHP on every script and save the output as HTML
#!/bin/bash
#Recursively searches a directory, executes PHP on every script and saves the output as HTML
find . -name "*.php" -exec bash -c 'php -B "error_reporting(0);" $1 > $(sed "s/\.t1$/.t2/" <<< "$1")' - '{}' \;

Keybase proof

I hereby claim:

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

To claim this, I am signing this object:

@howderek
howderek / derekdeck.js
Created May 29, 2013 19:12
JavaScript library to work with playing cards.
//derekdeck.js (c) 2013 Derek Howard
/*jslint browser:true*/
/*global escape*/
//the only global:
function Deck(empty, acesHigh) {
//construct a deck.
'use strict';
var i,
values;
empty = (empty === undefined) ? false : empty;
@howderek
howderek / prettyip.php
Created August 3, 2011 21:26
PrettyIP -- Nice looking simple PHP widget
<div style='width:140px;font-family:Helvetica, Helvetica Neue, Arial, sans-serif;background-color:rgba(0,0,0,.8);border:5px solid rgb(0,0,0);color:white;border-radius: 10px;'>
<p style='color:gray;text-align:center;font-size:.8em'>Your IP:</p>
<?
$ip=$_SERVER['REMOTE_ADDR'];
echo "<p style='color:white;text-align:center;'>$ip</p>";
?>
</div>