Saving the photos from my Nikon D60 onto my laptop running Ubuntu 8.04 was a bit problematic. F-spot worked initially but then it seemed a bit complicated and really I wanted to use picassa to manage my photos as it works so nicely.
Picassa wouldn’t import the photos from the camera and just froze when trying to do so, I installed f-spot again but that was having difficulty connecting to the camera for some reason.
I finally came across the perfect tool for simply getting the photos off the camera so I could move them and edit them on the computer and manage using picassa.
Continued…
Posted in Linux.
I was noticing some flickering watching dvds on Ubuntu 8.04 whilst running compiz. The flickering was even worse on those rare occassions I play a game. All this flickering went away when I disabled compiz, however, when enabling compiz again all the settings had been reset to defaults which was really annoying!
Here is the awesome fix for this behaviour, the compiz switch.
So easy to use, and it just works. It makes tip of the week.
Posted in Tips of the Week.
Tagged with compiz, tips, ubuntu.
cakePHP, saveAll() and Transactions
MySQL transactions and cakePHP, the two play nicely together. Its very easy to wrap your inserts and updates in transactions with cake:
Model->begin();
try {
if (!Model->save()) throw new Exception('Model did not save');
if (!Model->subModel->save()) throw new Exception('Sub Model did not save');
Model->commit();
}
catch (Exception $e) {
Model->rollback();
}
Continued…
Posted in Tips of the Week.
A simple method to paginate data seperately on a single page using the cakePHP paginator helper/object.
The Problem
In this case I want to paginate the news items, but I have a flag in the news item table for is_archive, so basically want to seperate the current news items from the archived ones and display both sets of data on the same page in two seperate tables. Then use cakePhp’s built in pagination to navigate through both sets of data independently of each other.
I used AJAX and the paginator options to get a very simple implementation working quite quickly.
Continued…
Posted in PHP.
I’m an identity theif.
I’ve been using the IRC channel for cakephp, jquery and others for a while now without a registered password, at first I thought I would just try it out, but as these IRC channels have become more and more handy it became time for me to register properly and stop impersonating someone else
I found the whole process slightly convoluted so here is the 1-10 of registering a nickname with Nickserv and joining an IRC channel using Pidgin on Ubuntu.
Continued…
Posted in Linux.
Tagged with irc, nickserv, ubuntu.