October 2011
1 post
7 tags
Project nearing completion... welcome CredRock!
The project that I’ve been working on, on-and-off for the last couple years is nearing completion. It’s a full stack software suite for ICANN Accredited Registrars. It’s modern, flexible, and has a RESTful API allowing all kinds of app integration for a Registrar.
The software design process on this has been a real treat. It’s quite a complex undertaking, including...
June 2010
2 posts
Fun with ActiveResource
So I’ve been using ActiveResource to consume a RESTful Rails API, and had embarked upon setting up forms for the ActiveResource web client. I’m a big fan of Formtastic, and have been using that for standard ActiveRecord forms for a while now, and figured I’d go ahead and try it with ActiveResource.
Well, just like the form_for helper, Formtastic relies on the the attributes...
May 2010
1 post
ZenCoding →
Just tried this out in TextMate, and it works a treat. I think this is going to replace my use of HAML.
March 2010
4 posts
3 tags
Maybe why you don't see recursion used much in...
You’re also highly likely to hit the stack limit in Ruby with recursion, and I don’t think there’s a simple way to alter the stack size.
jrwest:
I may be wrong but if my CS classes haven’t left me yet I believe you will find this in all programming languages. Iterative algorithms always run faster than recursive ones.
stevegraham:
I’ve become interested in recursion and...
3 tags
February 2010
6 posts
Silly User
clientsfromhell:
A client called complaining that she couldn’t access the company website. When I get there, this is what she had typed in the URL field: “the company website”.
A friend of mine once told me a story about when he was doing IT work for a local state election campaign. They told him that they backed up their entire user database every night…. on a single floppy disk....
We're still talking about SQL Injection... really?
I find it frightening that SQL Injection is still making the headlines. Back in 2000 we wrote a library for our ASP sites that took care of this. Yes, I said ASP. How is it that 10 years later this is still such a problem?
If you don’t think it’s an issue, check out this list of recent SQL Injection attacks, which includes the largest case of identity theft known in the US.
So...
4 tags
Upgrading to Rails 3 Beta
Today I attempted to upgrade a Rails app from 2.3.5 to 3.0.beta. I assumed this might be a monumental undertaking, and was prepared to cut things short if needed.
The bad news is that I did stop half way through, and have reverted to 2.3.5. The good news is the basic upgrade path was easier than I expected.
There’s now an official upgrade plugin which you can install into your existing...
Rails 3 Beta is Here →
2 tags
Master Lock Algorithm
A while ago I had come across the following cool tip and graphic on how to recover a combination for a Master Lock padlock you’ve forgotten.
The technique is a little algorithm that exploits a mechanical weakness in the lock to narrow down the last digit in the combination. You then use what is basically a lookup table to run through the possible combinations till you open the lock.
So...
January 2010
3 posts
2 tags
4 tags
nil?, empty? and blank?
rubyquicktips:
In Ruby, you check with nil? if an object is nil:
article = nil
article.nil? # => true
empty? checks if an element - like a string or an array f.e. - is empty:
# Array
[].empty? #=> true
# String
"".empty? #=> true
Rails adds the method blank? to the Object class:
An object is blank if it‘s false, empty, or a whitespace string. For example, “”, ” “, nil, [],...
5 tags
Google may pull out of China
Here’s an interesting post by Google on their problems in China, alluding to the possibility that they might close down Google.cn
http://googleblog.blogspot.com/2010/01/new-approach-to-china.html
Personally I’m not surprised. I’ve been firewalling all the servers I administer from all netblocks in China for a while now. If you’re not doing business in China, my advice is...
December 2009
3 posts
Conversation Plugin for Rails
Thought I’d post my new Ruby on Rails plugin here if it’s of interest to anyone. The plugin provides mixin conversation functionality. It’s ultra simple at the moment, and simply allows you to setup a conversation between two objects, and then send messages between those objects in the context of a conversation.
Please feel free to fork and ping me if anyone finds it of interest...
Firing up Tumblr
I’d created an account on Tumblr awhile ago, but haven’t yet had the chance to get into it and start posting…. so now seems the time.
Ready… set… tumbl!