Portfolio

Tony Hawk Ride Official Site

Posted in Portfolio on June 19th, 2009 by Eric Lamb – 1 Comment

Start Date: June, 2009
URL: http://thride.com
Technology: php5, MySQL 5.0, Prototype/Scriptaculous, Twitter API, cron

Purpose:
Provide a brochure site to promote the latest game in the Tony Hawk franchise.

Challenges:
This was the project that precipitated all the Twitter research I published.

The Twitter program works by searching Twitter for keywords or by user and includes a heavy duty filtering module for keeping undesirable users and keywords from showing up.

This was also my first attempt at doing an AJAX form with HTML_QuickForm, Smarty and Prototype/Scriptaculous.

Screenshots:

Tony Hawk Ride

Tony Hawk Ride

Bookmark and Share

Smarty Relative Datetime Modifier

Posted in Code, Portfolio, Programming on March 24th, 2009 by Eric Lamb – Be the first to comment

In Extending the Smarty Template Engine I outlined the steps needed to create all the varieties of plugins for the Smarty template engine. Continuing with that tutorial, and to provide a little context, here’s a quick Smarty plugin for converting timestamps into relative timestamps.

Smarty Logo

Smarty Logo

This is a Smarty module plugin; notice how the name conforms to the naming conventions with the prefix “smarty_modifier_”

<?php
/**
 * Smarty plugin
 * @package Smarty
 * @subpackage plugins
 */
 
/**
 * Smarty relative date / time plugin
 *
 * Type:     modifier<br>
 * Name:     relative_datetime<br>
 * Date:     March 18, 2009
 * Purpose:  converts a date to a relative time
 * Input:    date to format
 * Example:  {$datetime|relative_datetime}
 * @author   Eric Lamb <eric@ericlamb.net>
 * @version 1.0
 * @param string
 * @return string
 */
function smarty_modifier_relative_datetime($timestamp)
{
	if(!$timestamp){
		return 'N/A';
	}
 
	$timestamp = (int)strtotime($timestamp);
	$difference = time() - $timestamp;
	$periods = array("sec", "min", "hour", "day", "week","month", "year", "decade");
	$lengths = array("60","60","24","7","4.35","12","10");
	$total_lengths = count($lengths);
 
	if ($difference > 0) { // this was in the past
		$ending = "ago";
	} else { // this was in the future
		$difference = -$difference;
		$ending = " from now";
	}
	//return;
 
	for($j = 0; $difference > $lengths[$j] && $total_lengths > $j; $j++) {
		$difference /= $lengths[$j];
	}
 
	$difference = round($difference);
	if($difference != 1) {
		$periods[$j].= "s";
	}
 
	$text = "$difference $periods[$j] $ending";
 
	return $text;
}

Installation

Just copy the contents above and paste into a file called:
modifier.relative_datetime.php

Place the file in your Smarty plugin directory and you’re good to go.

Usage Example:

{$item.timestamp|relative_datetime}
Bookmark and Share

iTunes Data Wordpress Widget

Posted in Code, Portfolio on March 15th, 2009 by Eric Lamb – 2 Comments

Here’s just a quick announcement for a new WordPress widget I’ve written call iTunes Data. It’s a sidebar widget that displays snippets from an uploaded iTunes XML file.

iTunes

iTunes

Currently, the data that gets displayed in the widget is randomized to pull the following:

  1. Top Genres
  2. Latest Additions
  3. Top Artists
  4. Top Albums

I’ve actually had the basics done for quite some time. It’s been on my site, plugging along, which has helped me to make sure it was efficient and worked properly.

The cool thing about building the widget was learning about PclZip, something I’ll be writing more about soon. For now though, let me just say it’s a really nice zip file management class that allows for easy work.

The widget couldn’t have been built without the iTunes XML parser for PHP library written by Robert A. Wallis

Anyway, until I build a proper page for the widget and get it into the WordPress Plugin Repository, you can download it below.

Download iTunes Data Widget

Bookmark and Share

WP-Click-Tracker 0.3

Posted in Code, Portfolio, Programming on February 1st, 2009 by Eric Lamb – Be the first to comment

I’ve updated the repository with the latest version tonight.

This release includes a couple bug fixes and a few improvements.

Improvements

  • Added Indexes on tables for better performance
  • Updated Install system
  • Added pie charts for clicks by day and hour

Bug Fixes

  • fixed hour click report formatting
  • fixed blank link haunting
  • fixed option saving

Screenshots

Clicks By Hour Pie Chart

Clicks By Hour Pie Chart

Day Clicks Pie Chart

Day Clicks Pie Chart

Bookmark and Share

Endwar Community

Posted in Portfolio on December 29th, 2008 by Eric Lamb – Be the first to comment

Start Date: August, 2008
URL: offline;
Technology: php5, MySQL 5.0

Purpose:
Build a community to promote the Ubisoft title EndWar.

Challenges:
Communication and collaboration. This was the first project with Ubisoft and a new web producer so getting used to how both worked was interesting. I learned alot from both parties.

Screenshots:

Missions

Missions

Homepage

Homepage

Bookmark and Share

Charlie Oscar Delta

Posted in Portfolio on December 29th, 2008 by Eric Lamb – Be the first to comment

Start Date: May, 2007
URL: offline; contact for access
Technology: php5, MySQL 5.0

Purpose:
Build a community to promote the Activision title Call of Duty 4.

Challenges:
This site was to be a social network style community site with all the bells and whistles that required; invite system, friend framework and challenge management. To give you an idea of scale the project started out with a single web/db server combo and ended up with 8 web servers and 3 database servers.

Screenshots:

Age Gate

Age Gate

Homepage

Homepage

Top Members

Top Members

Bookmark and Share

Kung Fu Panda

Posted in Portfolio on December 29th, 2008 by Eric Lamb – Be the first to comment

Start Date: April, 2008
URL: http://www.kungfupandagame.com
Technology: php5, MySQL 5.0

Purpose:
Promote and drive interest in the upcoming Activision game Kung Fu Panda.

Challenges:
This project was a flash based client side with a php backend website. The client side needed to be localized for an unknown amount of languages (we weren’t told until and include a mini-game, in-depth tracking and be XML driven. The biggest challenge, though, was that the client needed a system to assign editing status to a particular moderator with each moderator being able to edit multiple languages.

Screenshots:

Language Select

Language Select

About the Game

About the Game

Videos

Videos

Bookmark and Share

Game of the Year

Posted in Portfolio on December 22nd, 2008 by Eric Lamb – Be the first to comment

Date: January, 2007
URL: http://gameoftheyear.callofduty.com
Technology: php5, MySQL 5.0

Purpose:
Allow users to enter in a “keycode” and get an Xbox360 download token code in return. The token code was used to download the Variety Map Pack for Call of Duty 4.

Challenges:
The client needed to know which token code was redeemed by which keycode so this project required special attention to how the keycodes were being redeemed. Additionally, a robust reporting tool was required to display which keycode was used, at which time, and from which organization the keycode came from.

Screenshots:

Homepage

Homepage

Bookmark and Share

Clique Community

Posted in Portfolio on December 22nd, 2008 by Eric Lamb – Be the first to comment

Date: April, 2008
URL: http://www.thecliquemovie.com/
Technology: php5, MySQL 5.0, ImageMagick

Purpose:
Community for the kids interested in the upcoming Clique movie.

Challenges:
This was an interesting project because, once again, we didn’t have direct contact with the client. We dealt with a third party on all change orders so this affected delivery time lines dramatically. It would sometimes take weeks between hearing about a proposed change for it to be officially requested so there was a whole log of “hurry up and wait”.

Screenshots:

Home

Home

Banners & Icons

Banners & Icons

Bookmark and Share

I Am Legend Community

Posted in Portfolio on December 22nd, 2008 by Eric Lamb – Be the first to comment

Date: January, 2007
URL: http://www.i-am-immune.com
Technology: php5, MySQL 5.0, ImageMagick

Purpose:
Official community for the I Am Legend movie.

Challenges:
There really wasn’t too many things outside the box for this site. The biggest challenge would have to be the expected load. We needed another load balancer and 3 web servers with 1 database server.

Screenshots:

I Am Legend Homepage

I Am Legend Homepage

Register for I Am Legend Community

Register for I Am Legend Community

Bookmark and Share