Unique Marketing, Guaranteed Results.

Accessibility: A Few Things Everyone Should Do

April 14th, 2009 by Mister Mc

Creating web pages that are accessible for people with disabilities is also a step in the right direction for making your site user-friendly for the rest of your audience.  Observing your work from a different perspective will give you insights on how you can improve.  For instance, what does your page look like when style sheets or images are disabled?  What will your site sound like when read by screen reading software?  How does the page look when loaded on a mobile device?  There are a few simple things everyone can do to avoid acessability problems.

Read the rest of this entry »

Ruby Chop vs Chomp

April 14th, 2009 by jaredd

When you receive user input from textareas or console input you may get some newline characters. One way to remove newline characters is the String#chop method, it will remove any trailing newline or carriage return characters “\r\n”. But it’s tricky. Because here it works like it’s suppose to.

full_name = "My Name is Jared\r\n"  
full_name.chop! # => "My Name is Jared"

Now if you run chop and there are no newline characters.

puts full_name    #=> "My Name is Jared"
full_name.chop!  #=> "My Name is Jare"

Disaster Strikes!

That’s why there is chomp.

puts full_name       #=> "My Name is Jared\r\n"
full_name.chomp!  #=> "My Name is Jared"
full_name.chomp!  #=> "My Name is Jared"

So chomp is our recommended way of removing trailing newline characters.

The Fundamental Rule of Computing

April 13th, 2009 by jaredd

I have created my own fundamental rule of computing. And I call it “The Fundamental Rule of Computing”
And it consists of three parts:

Backup everything.
Backup everything to an offsite location.
Backup everything to another offsite location.

Test One Cucumber Feature File at a Time

April 10th, 2009 by Chris Gunnels

To most this may sound commonplace. (definition 2).

So I was banging my head for a hour to find out how to test one feature file at a time. If you don’t know how to do this yet then you’ll want to follow along, if you do, then just read another post and make a good comment!

If this sounds like you:

“I have multiple cucumber feature files in the features folder within my app, I want to test one of those files and not all of them at once, but don’t know how.”

Then you’re in for a treat.

Read the rest of this entry »

Interactive Ruby With Tab Completion

April 10th, 2009 by Aaron Murphy

Do you like tab completion with bash? Now you can have it with irb too! Just setup your .bashrc file with an alias so you don’t have to remember the entire command line. It’s not exactly the same as bash. You will have to hit the tab key twice. On my Ubuntu 8.10 system it works as listed below.

Read the rest of this entry »

Yield to the Ruby Master

April 9th, 2009 by justin

After a time of much outer influence and inner struggle, I, a self-proclaimed Microsoft fanboy, decided to abandon everything I’ve known for the last 6 years as a .NET developer and sample the sweet simplicity and sheer power that is Ruby on Rails.

One of the first things I learned while working on my first Rails project was the use of Ruby’s yield statement.  Coming from C#, I expected the yield statement to act a bit differently than it does in Ruby.  Basically, the yield statement is provided as a way to ease the creation of iterators.  It gives control to a user-specified block from within a method’s body.

Read the rest of this entry »

Usability: The Least You Can Do

April 9th, 2009 by Mister Mc

I recently read the very likable and popular book Don’t Make Me Think by Steve Krug.  I think it should be required reading for anyone who does anything with web design and development or software.  The author’s examples are clear, authoritative, and presented with humor, which makes cruising through this book enjoyable and interesting.  I can’t tell you how many “Head Slappers” (to borrow Krug’s usage of the cliché) I experienced while reading.  So many of his ideas seem obvious, but are not common place yet.

Read the rest of this entry »

Tutorial: How to install/setup Cucumber

April 9th, 2009 by Alan Carl Mitchell

This tutorial assumes that you have ruby, rails, and mysql installed on your machine, and doesn’t explain too much about Cucumber and will mostly show you a quick way to get it working. A lot of material is borrowed from this tutorial on setting up RSpec and Factory Girl. It may be useful to look over first, but not necessary.

Read the rest of this entry »

Social Networks and Posting Effective Comments

April 8th, 2009 by Brandon Buttars

Social Networking and CommentingI just got done reading a couple of different articles about commenting effectively and pulled some really good information from them both but I have even some more advice on commenting.  One thing that I have learned more recently not only about commenting but about combining commenting and social networking is that you can generate quite a bit of traffic if done right by helping the blogs and sites that you make comments on get traffic on sites like Digg and Reddit.

Read the rest of this entry »

PowerDNS With Empty CNAME = Fail!

April 7th, 2009 by Aaron Murphy

Just used up my morning trying to resolve an MX record problem. We were not getting our email through our new Google Apps account. I tried to send from Gmail to myself and it worked. I tried to send to someone else in our domain, and got a “550 550 Unrouteable address (state 14)” error.

Read the rest of this entry »

Copyright © 2005-2011 PMA Media Group. All Rights Reserved