Skip to content

Instantly share code, notes, and snippets.

@technosailor
technosailor / fcc.txt
Created November 9, 2011 18:47
FCC Announcement on Global Broadband Initiative
Below is (1) the text of Chairman Genachowski's remarks on broadband adoption national programs, made today at the Langley Education Campus in Northeast Washington, D.C., and (2) a summary of supporting statements on the initiatives from Connect to Compete company and non-profit partners.
CHAIRMAN JULIUS GENACHOWSKI
REMARKS ON BROADBAND ADOPTION
WASHINGTON, D.C.
NOVEMBER 9, 2011
@technosailor
technosailor / gist:1478410
Created December 14, 2011 20:41
Hook onto user_register
<?php
function do_extra_user_stuff( $post_id )
{
add_to_ldap_or_something( $post_id );
}
add_action( 'user_register', 'do_extra_user_stuff' );
@technosailor
technosailor / gist:1562940
Created January 5, 2012 00:02
Awesome spam
Hello,
I am looking for someone who can handle my Personal and Business errands at his/her spare time. Someone who can offer me these services: Mail services, Receive my mails and drop them off at the Post ,Shop for Gifts Bill payment ( pay my bills on my behalf),Sit for deliveries( at your home) or pick items up at nearby Post Office at your convenience.
I would love to meet up with you to talk about this job but I am currently away on business. I am in Switzerland so there will be no interview. I will prepay you in advance to do my shopping. I will also have my mails and packages forwarded to your address. If you will be unable to stay at your house to get my mails, I can have it shipped to a post office near you and then you can pick it up at your convenience. When you get my mails/packages; you are required to mail them to where I want them mailed to. You don't have to put money out of your pocket, all you have to do is have packages shipped to your house and do my shopping. You are allowed to open the p
@technosailor
technosailor / gist:1672182
Created January 24, 2012 19:52
Formula for a Day
class Technosailor_Day {
public var $coffee;
public function __construct( $coffee = 5 )
{
$this->coffee = $coffee;
$this->is_productive();
}
<?php
function foo_remove_bbp_for_subscribers()
{
if( !current_user_can('subscriber') )
return false;
if( !class_exists('BBP_Admin') )
return false;
<?php
/*
Plugin Name: Test
*/
class My_Like_Button {
function __construct()
{
$this->hooks();
}
<?php
include( './wp-load.php' );
$dbs = $wpdb->get_col('SHOW DATABASES');
foreach( $dbs as $db )
{
$tables = $wpdb->get_col( sprintf( "SHOW TABLES IN %s", $db ) );
foreach( $tables as $table )
{
<?php
class Fun_Stuff {
function __construct()
{
$this->hooks();
}
function hooks()
{
<?php
class AMM_Template_Tags {
public function __construct() {}
public function display_featured_video()
{
$amm_options = get_option( 'amm_options' );
$video_url = $amm_options['featured_video']; // http://www.youtube.com/watch?v=S-PcsfPPUsE
if( !$video_url )
<?php
public function show_profile()
{
$profile = $this->profile_type;
$this->_amm_{$profile}_listing();
}