Skip to content

Instantly share code, notes, and snippets.

View mitchellhislop's full-sized avatar

Mitchell Hislop mitchellhislop

View GitHub Profile
Main column
$wp_meta_boxes['dashboard']['normal']['core']['dashboard_right_now']
$wp_meta_boxes['dashboard']['normal']['core']['dashboard_recent_comments']
$wp_meta_boxes['dashboard']['normal']['core']['dashboard_incoming_links']
$wp_meta_boxes['dashboard']['normal']['core']['dashboard_plugins']
Side Column
$wp_meta_boxes['dashboard']['side']['core']['dashboard_quick_press']
$wp_meta_boxes['dashboard']['side']['core']['dashboard_recent_drafts']
$wp_meta_boxes['dashboard']['side']['core']['dashboard_primary']
$wp_meta_boxes['dashboard']['side']['core']['dashboard_secondary']
// Create the function to use in the action hook
function example_remove_dashboard_widgets() {
// Globalize the metaboxes array, this holds all the widgets for wp-admin
global $wp_meta_boxes;
// Remove the quickpress widget
unset($wp_meta_boxes['dashboard']['side']['core']['dashboard_quick_press']);
@mitchellhislop
mitchellhislop / Multi-cell functions in GDocs
Created February 16, 2011 18:00
This is the starting point for doing multi-cell work in one cell
=arrayformula(sum({d4:d50} * (.01*{g4:g50})))
- simple
- public over private
- personal vanity
- internet is global
- permalinks
- one important item per page
- don't break the browser
- don't wanker in technology
- a medium is not a grande
- break convention for your users
@mitchellhislop
mitchellhislop / directions_view.php
Created December 7, 2010 19:35
PHP Google Directions API
<head>
<title>Your Trail</title>
</head>
<body>
<h1>Your Trail</h1>
<?php
echo "<br />";
echo '<h1>Directions:</h1>';
echo '<h2>Start: '.$origin.'</h2>';
foreach ($directions->route as $route)
CREATE TABLE `user` (
`twitter_id` int(10) unsigned NOT NULL,
`created_at` timestamp NOT NULL default '0000-00-00 00:00:00',
`name` varchar(80) NOT NULL,
`screen_name` varchar(30) NOT NULL,
`location` varchar(120) default NULL,
`description` varchar(640) default NULL,
`profile_image_url` varchar(400) NOT NULL,
`url` varchar(100) default NULL,
#!/usr/bin/env ruby
# twail.rb
# Twitter stream tail
# Copyright 2010 Jonathan Rudenberg
# Licensed under the MIT License
#
# Prerequisites: gem install json twitter-stream
require 'optparse'
<?php
class Scrape {
public $headers = array();
public $result;
public $error;
Change the HTML at the top to:
<html xmlns:og="http://opengraphprotocol.org/schema/"
xmlns:fb="http://www.facebook.com/2008/fbml">
Add these in the <head>
<meta property="og:title" content="Auto Repair Shop Search"/>
<meta property="og:site_name" content="Your Neighborhood Auto Repair Pro"/>
<iframe src="http://www.facebook.com/plugins/like.php?href=http%253A%252F%252Fautorepairpro.net&amp;layout=standard&amp;show_faces=false&amp;width=450&amp;action=recommend&amp;font&amp;colorscheme=light&amp;height=35" scrolling="no" frameborder="0" style="border:none; overflow:hidden; width:450px; height:35px;" allowTransparency="true"></iframe>