Entries for the ‘PHP’ Category

Find parent form in jQuery

Needed to find the parent form of a form element. This answer on StackOverflow gave me the right answer.

DropBox vs SugarSync – Or why I’m keeping DropBox

I’ve used DropBox for quite some time now and loved it. When I needed more default storage, however, a friend pointed me in the direction of SugarSync. SugarSync offers a range of different features, but my clear favorite is the ability to flag any folder on my machine as a sync folder. No longer do [...]

Recursive Stored Functions in MySQL

I have only recently started working heavily with stored procedures and functions in MySQL. After years in the Oracle world with advanced stored procedures, functions and packages, I’ve had to come to grips with the shortcomings of MySQL. One of those is recursive functions. MySQL allows recursive stored procedures, but not recursive stored functions. Here [...]

number_format modifier for Template_Lite

Anyone else puzzled why the Template_Lite template engine for PHP does not include a number_format modifier by default? I was. I googled and didn’t find one in my short search so here it is: function tpl_modifier_number_format($number, $decimals) { if(!empty($number)) { return number_format($number, $decimals); } else { return number_format(0, $decimals); } } Just save that into [...]

CodeIgniter + qqFileuploader – UPDATED to support IE

I’m using CodeIgniter in a project with the AJAX file uploader qqFileUploader. I wanted my CI controller to handle the upload work for the file uploader instead of a PHP script that lived outside the CI framework. To make this work made a few minor changes to the qq files and I made some changes [...]

CodeIgniter PHP Framework

Been spending a lot of time using the PHP MVC framework CodeIgniter, lately. If you’re familiar with Ruby on Rails or Tapestry for Java you’ll love CodeIgniter in the PHP world. I’ve looked at other frameworks many times in an effort to find something with a good ActiveRecord pattern and MVC2 pattern. CI fits the [...]