Design Patterns

Posted on August 9th, 2006 in PHP by Russ

The more I read about ‘Design Patterns,’ the more I consider myself an OOP beginner. Here’s an example of my OOP coding style:

class foo {
var x;
var y;
function foo( $inputx, $inputy) {
$this->x=$inputx;
$this->x=$inputy;
}
function mult() {
return $this->x * $this->y;
}
}

The methods (functions) defined for the class are fairly simple, and basically just functions wrapped in a class wrapper. I’m not “leveraging” the usage of a class for inheritance or amorphism; I’m just writing functional code that’s designed to look like OOP code. This is definately a place for me to improve upon.

New Site Up

Posted on August 7th, 2006 in Search Engines by Russ

I’ve recently pulled together a site I’m calling elibratto. It’s kind of an experiment; an unabashedly affiliate-oriented site. Most of the links on the page go to pages at Amazon.com with my affiliate key. It’s heavily templatized and very … boring on the back end. On the back end too, there is an automatic once-weekly script that runs to get the most-read books in each of the genres. Costs for putting together the site were about $8.00 for the domain and about $120 for the work (6 hours of programming that other people pay me $20/hour for). If the site makes enough to pay for the domain, I’ll be satisfied; if it makes enough to pay for the programming, I’ll be happy; if it makes much more than that, I’ll be thrilled. ;)

This is in response to a co-workers claim that their affiliate sites bring them in excess of $3000/monthly for a few hours of maintenance a week.

I will admit that the site needs some prettying love. My timeline has that completed by Friday. I’m thinking I could also present each genre’s list as an RSS feed, because that’s one thing I couldn’t find out there in the wild (my original thought was to take an automatically generated list and then build the affiliate links from that). I’m also thinking about some more inter-links, like “other books by this author” and stuff; but for much more development like that, I’ll wait to see some traffic on the site; if it’s not getting the traffic I want, there’s no need to sink more development into it.