The ‘Computer programming’ Archives
Posted November 3, 2011 by

Xcode 4: Add Existing Framework

When developing in Xcode, adding frameworks is a common action. How to add frameworks has changed from Xcode 3 to Xcode 4. Here are the steps required in the latest version.

Posted November 2, 2011 by

Two Common Mistakes in Floating Point Arithmetic in C

This tutorial will demonstrate two rules that must be respected when performing floating point arithmetic in C. Following these rules will prevent loss of information. Examples with walk through explanation provided.

Category C programming

Posted February 1, 2011 by

Symfony 1.4: Add and Update Created_at and Updated_at Fields Automatically

After the CRUD building process with symfony, beginners are often perplexed with the handling of the created_at and updated_at fields on their forms. These fields are typically best handled behind the scenes. Here is how to let symfony take control of these fields automatically.

Category Symfony

Posted February 1, 2011 by

Symfony 1.4: Widget Does Not Exist Error after Unset

With symfony’s form builder, users will need to unset several common fields such as created_at and updated_at. Beginners frequently experience a “widget does not exist” error after unsetting form fields.

Category Symfony

Posted April 2, 2010 by

Create NSIndexPath for UITableView in iPhone/iPad App

Once you get past basic table view applications on the iPhone or iPad, you may run into the need to create an instance of NSIndexPath. NSIndexPath is an interesting class that stores the path to get to something in a nested set of collections. In an iPhone UITableView application, NSIndexPath is central as it provides […]

Posted March 19, 2010 by

PHP: Camel Case to Spaces or Underscore

Recently while working on a project, I found I needed to convert camelcase strings to space-separated strings. This same technique will work if you want to convert camelcase to underscore separation as well.

Category PHP programming

Posted March 5, 2010 by

Symfony: Detect Which Version is Installed

The Symfony php framework is frequently updated. Detecting which version is actively installed, however, is not well documented. Here is how to do it.

Category Symfony

Posted January 30, 2010 by

Cocoa: Convert number to comma-separated NSString

At some point in your Mac, iPhone, or iPad development you may find the need to express a long number (1000000000) as a comma-separated string (1,000,000,000) to make life easier on your users. The NSNumberFormatter class is a rich tool for converting numbers to strings supporting different types of currencies and localizations. It’s also the […]

Category C programming

Posted November 25, 2009 by

Symfony: Drop Down List Box Without Submit Button

I needed a drop down list box for a symfony site I was designing. As a newbie symfony programmer, I wanted to record this so I could reference it later. Although this uses a little javascript, it will correctly function and is backwards compatible to users without javascript enabled.

Category Symfony

Posted February 12, 2009 by

Pear Fix for “Error: Unable to Unpack”

Recently while trying to install some Pear packages, I received an odd “Error: Unable to Unpack” message. A search for this error message found a lot of complaining people and not a lot of answers. I finally figured out the cause and the fix for this common Pear problem.

Category PHP programming

Posted October 20, 2008 by

Cocoa: Explode or break an NSString into individual words

Breaking apart a string of text into component words is a requirement for performing searches in text and other text processing. This task is easy in Cocoa/Objective-C, although it requires digging through a few class references in the documentation. If you need a more complicated expansion of a string, at least this code will give […]

Posted September 30, 2008 by

PHP: Upload Files to the Server

With PHP, it is simple to upload any file to your server.

Category PHP programming