Recent Posts

Uncategorized

Deducting Business Startup Costs

Tim Barsness • March 29, 2010

For the most part, business start-up costs and organizational costs must be deducted over a 180-month (15 year) period. For example, if your start-up costs were $18,000, and you started your business on August 1, 2009,…

Read More

Uncategorized

Getting your Google Base Items to be listed in main comparisons

Tim Barsness • March 24, 2010

I have recently been listing items for sale onto Google Base through XML Feed created by a custom PHP script. There was an issue that I was having trouble fixing however. All my items were at…

Read More

Uncategorized

Curly Braces in Mysql Queries

Tim Barsness • March 23, 2010

I came across a few queries in our newest project and noticed a bunch of them injected their variable data inside curly braces. I come to find out you can use this in any string in…

Read More

Uncategorized

FPDF

Tim Barsness • March 15, 2010

I’m considering using FPDF as a solution to creating PDF’s on Debian since FDFlib isn’t installed. It isn’t as efficient as the native PDFlib, but apparently is sufficient for most things. I’m impressed so far. If…

Read More

Uncategorized

How To: Read a CSV in PHP

Tim Barsness • February 23, 2010

Reading a CSV in PHP is much easier than I anticipated with the advent of the fgetcsv() function for PHP 4. The function basically reads a file line by line and performs and explode on the…

Read More

Uncategorized

How to Send an Email using PHPmailer and Gmail for SMTP

Tim Barsness • January 14, 2010

I needed to offer a client the ability to send Email using PHPmailer and Gmail. The below is what I came up with, which worked flawlessly: require("PHPMailer_v5.1/class.phpmailer.php");   $mail = new PHPMailer();   $body = "Message…

Read More

Uncategorized

WordPress in_tree() function

Tim Barsness • January 11, 2010

Just created a wordpress funciton in_tree($a, $b) which checks to see if page ID $a is in the tree of page ID $b. That is, it checks to see if $a is a child of $b…

Read More

Uncategorized

Using sys_get_temp_dir() in PHP < 5.2.1

Tim Barsness • December 30, 2009

I wanted to use the PHPExcel package on my Debian system running 5.2.0, however PHPExcel 1.7.1 requires the sys_get_temp_dir() function which doesn’t exist prior to PHP 5.2.1.  Of course aside from updating PHP, we would need…

Read More

Uncategorized

How to Hide a WordPress Sidebar From Pages

Tim Barsness • December 22, 2009

In combination with my previous post on adding multiple sidebars to a WordPress theme, I had the need to display one of them only when looking at the blog part of wordpress. This is pretty straightforward,…

Read More

Uncategorized

How to Add a Sidebar to a WordPress Theme

Tim Barsness • December 21, 2009

I recently needed a little more control over the sidebar on a theme and had never added a sidebar to a theme before. I wanted certain widgets to show up only on posts and the rest…

Read More

Uncategorized

How To pass an Array in the Querystring Using PHP

Tim Barsness • December 18, 2009

I recently ran across a silly WordPress situation where I needed to pass an array in the querystring.  Here’s what I came up with: $array = array(’a’ => 1, ‘b’ => 2, ‘c’ => 3); $array…

Read More

Uncategorized

WordPress Custom Author Page (author-x.php)

Tim Barsness •

It was recently asked in a newsgroup how to make the WordPress author function like the wordpress category page. The format of the category page is category-x.php. Replace the x with the category ID you would…

Read More

Uncategorized

How to Get Google Voice Call Length in PHP (Google Voice API)

Tim Barsness • December 8, 2009

I am interested in building a google voice / highrise mashup that tags people by how long overall I’ve talked to them. I ran across this bit of PHP code by Aaronpk that attempts to use…

Read More

Uncategorized

$_Get Getter 1.1

Andy Stramer • December 7, 2009

Thanks to the help of Daniel Watrous, an improved version of our $_Get Getter WordPress plugin is now available. It is now able to pull multiple variables from the query string. You can get the new…

Read More

Uncategorized

WordPress Search and Replace

Tim Barsness • December 3, 2009

I just ran across a WordPress search and replace plugin.  I don’t have an immediate use for it, but with how much search and replace I do, I know it will come in handy. The plugin…

Read More