Year: 2012

all hail the latest meme to capture the hearts of the internet: grumpy cat:

Grumpy-Cat-MEME-01

so here’s my little sketch:

grumpycat

download the pdf to print out!

Read more »

originally found this on josh stauffer’s site. just wanna add to my site so i can pull it up easily

$slug = basename(get_permalink());

needed to do this to make wordpress choose the thumbnail image instead of the full-sized image — since some people like to upload gernormous images (recall that wordpress uploads a whole set of images when you upload one)

so this adds a suffix (in this case, “-150×150”) to the of the filename, BUT before the file extension

anyway, here it is:

// set your suffix
$thumbnail_suffix = "-150x150";

// $featured_image is the filename. this would be determined above this code snippet
// determine the length of the filename, including the extension
$length = strlen ($featured_image);

// get the first part of the filename (before the extension)
$temp1 = substr ($featured_image, 0, $length-4);

// get the second part of the filename (the extension)
$temp2 = substr ($featured_image, $length-4, $length);

// stick the suffix in between the two halves
$featured_image_updated = $temp1.$thumbnail_suffix.$temp2;

you might be saying, “but joey.. why don’t you just use something like explode to break up the filename?” well you really don’t know what the filename will be — it could have a bunch of dots in it… if you could figure it out, great. let me know what you did.

at least you know every image file that’ll be uploaded will be a “.” and then three characters after.

tried this out the other day… dennis’ recipe — i’d marinate the meat — preferably flap meat — overnight

Ingredients

  • fresh cracked pepper
  • flap meat (best deal is at costco)
  • 1 lemon — halved and squeezed
  • ½ garlic — finely chopped
  • korean bbq marinade — this can be purchased at any grocery store in the asian aisle
  • heavily season with salt and pepper
  • 1 can sprite
Read more »

was challenged at work and couldn’t think of a proper solution. i knew it was possible, but didn’t know how to execute it

this is what happens when you don’t know all the tools you have available to you…

thank god for the wordpress community

background

this makes absolutely no sense without any background! essentially i have a splash page that goes to several sub-sites. when you get to a sub-site, i want each sub-site’s home to go back to its own home location, not the splash page, which would be

< ?php echo get_option('home'); ?>

code

< ?php //parent variables
	$parent = get_post($post->post_parent);
	$parent_title = get_the_title($parent);
	$grandparent = $parent->post_parent;
	$grandparent_title = get_the_title($grandparent);?>

	< ?php // is the homepage the granparent?
	if ($grandparent == is_page('0')) { ?>
	<li><a href="/<?php echo get_permalink($grandparent); ?>">Back to < ?php echo $grandparent_title; ?></a></li>
	<li><a href="<?php echo get_permalink($post->post_parent); ?>">Back to < ?php echo $parent_title; ?></a></li>

	< ?php // is the homepage the parent?
	} elseif ($post->post_parent ==is_page('0')) {?>
   <li> <a href="<?php echo get_permalink($post->post_parent) ?>">Back to < ?php echo $parent_title; ?></a></li>

    < ?php // I must be a top level page!
	} else { ?> <!-- no parent to show -->
< ?php }?>

took matty to the padres game today and dennis took andy. i didn’t expect much from the team. they’ve been hit with so much bad luck this year — i thought they were going to be middle of the pack at least, not bottom of the barrel.

anyways, this is the first time i brought my nex-3 to the ballpark… enjoy!

thanks to andy for the bomb seats!

photos

yonder alonso

Read more »

sarmad, sharon, and baby marcus are in town so the gang got together… rolled around la jolla and windandsea beach, his old haunts…

sharon turned in early so we headed west so sarmad can see the sun set into the ocean

Read more »

matty and andy played in their respective little league all star games today. andy made some great plays on the field and matt threw a 6-pitch, 1-2-3, 6th to get the save for his team.

you’ll notice i’ve put a filter on my pics… just wanted to experiment with some new toy: nik color efex pro. i ran the pics through its film efex: fuji 800z filter. it gives it a near realistic film look… i need to play with that app a little more Read more »

reception: imperial palace, pasadena, california

the venue for the reception was amazing. you hear the name “imperial palace” and think of a scary las vegas hotel/casino where people get shanked, but this one was classy. huge space with a nice dance floor and top-class lighting and sound.

it was a fun reception, though all my shots turned out purple because of the LED lights

oh yea… and this:

Read more »