So Anthony and the Internets have given me the best possible gift for my birthday this year. Maybe even better than the news of the new season of Venture Brothers.
The entire first (only) season Manhattan AZ is on Hulu! This means nothing to any of you fuckers out there because obviously no one watched it as it was cancelled after 8 episodes.
So go to Hulu, watch all 13 episodes. I promise LOLs will be had.
Posted in Silly Goosery | No Comments »
The greatest thing that could ever happen in my life has happened. That's right. There's a new season of Venture Brothers.
A preview aired at the New York Comic-Con, and now we the wonderfulness here to share with you. The new season premieres June 1st on adult swim.
Posted in Silly Goosery, Video | 3 Comments »

If iTunes gives you the error "An iPod has been detected, but it could not be identified properly" when you plug in your iPhone, try this before spending an hour and a half on the phone with Apple.
Unplug everything that's plugged into your computer's USB ports. Especially look for mass storage devices. External hard drives, jump drives, etc.
In my case I had an old SanDisk Cruzer Micro, which I almost never use, plugged in. I think it was confusing iTunes for some reason. It would detect the iPhone, and then think the USB drive was the iPhone and couldn't read the identifying info from it. Or not, I mostly just made that up but it sounds good, right?
Anway, unplug your crap and try again. If that doesn't work for you then keep trying, and if you figure it out leave the solution in the comments.
Posted in Geekery, Useful Junk | No Comments »
See that lil' radio button that says "Structure and data"? Well. If you're backing up a database table using SQLyog, make sure you check that if you plan on dropping the original table.
Oops. Sorry JC 
Posted in Geekery | 2 Comments »
Well, WordPress got borked yesterday when I installed a bunch of plugin updates. I fixed the syntax highlighting by writing my own plugin. It just takes Geshi and does some extra regular expressions to make it look the same in WordPress as it does in E-Texteditor. Here's an example:
/**
* Parser Controller
*
**/
class Parser extends Controller {
/**
* Parser Constructor
*
* @return void
**/
public function Parser() {
parent::Controller();
$this->load->library('highlighter');
}
/**
* Default Parser Page
*
* @return void
**/
public function index() {
// We're going to test it by having it render itself.
$code = file_get_contents(
'system/application/controllers/parser.php'
);
$this->load->view('highlight_test', array(
'code' => $this->do_highlight($code, 'php')
));
}
/**
* Do the syntax highlighting
*
* @return string The highlighted source code
**/
private function do_highlight($code, $lang) {
$highlighted_code = $this->highlighter->syntax(
$code,
$lang
);
// Run extras that Geshi missed
$highlighted_code = $this->do_highlight_extras($highlighted_code, $lang);
return $highlighted_code;
}
/**
* Since Geshi sucks a fat cock, I have to put these here. I couldn't
* get Geshi to do this for me. This should be redone in Geshi if possible.
*
* @return string The highlighted source code with highlighted extras
**/
private function do_highlight_extras($code, $lang) {
// Define the extra function to run based on the selected language
switch($lang) {
case 'php':
$extras = array(
'class_names',
'extends_class_names',
'scope_resolution_operators',
'dash_arrows'
);
break;
default:
// We don't have any to take care of, so just exit out
return $code;
}
// Loop through the extra functions, and if they exist, run em.
foreach($extras as $extra) {
$method = 'highlight_' . $lang . '_' . $extra;
$code = $this->$method($code);
}
return $code;
}
/**
* PHP Source Extra
* Find all of the class names and highlight them.
*
* @return string The highlighted source code including this extra
**/
private function highlight_php_class_names($code) {
$result = preg_replace(
'/\>class\<\/span\> ([A-Za-z0-9_]+)/',
'>class</span> <span class="re3">$1</span>',
$code
);
return $result;
}
/**
* PHP Source Extra
* Find all of the class names that extend another class and highlight them.
*
* @return string The highlighted source code including this extra
**/
private function highlight_php_extends_class_names($code) {
$result = preg_replace(
'/\>extends\<\/span\> ([A-Za-z0-9_]+)/',
'>extends</span> <span class="re3 it">$1</span>',
$code
);
return $result;
}
/**
* PHP Source Extra
* Find all ::'s and highlight them.
*
* @return string The highlighted source code including this extra
**/
private function highlight_php_scope_resolution_operators($code) {
$result = str_replace(
'::',
'<span class="kw2">::</span>',
$code
);
return $result;
}
/**
* PHP Source Extra
* Find all of the ->'s and highlight them.
*
* @return string The highlighted source code including this extra
**/
private function highlight_php_dash_arrows($code) {
$result = str_replace(
'->',
'<span class="kw2">-></span>',
$code
);
return $result;
}
}
Posted in General Boringness | No Comments »