Archive for July, 2009
How to order by most recently updated in Rails
Posted by admin in Ruby on Rails on July 28, 2009
This is a simple one but sometimes hard to figure out for beginners in Rails. There are a number of ways to do it but this is one of the most simple. It includes actually doing a sql query inside your find method.
@posts = Post.find(:all,rder => 'updated_at DESC')
That’s it. I’m ordering by the updated_at column in the Posts table.
Tracking What’s Hot with Ruby Toolbox
Posted by jdempcy in Ruby on Rails on July 14, 2009
Knowing what software is popular, current and updated regularly is a crucial aspect to developing successful websites. All developers benefit from being knowledgeable about what software is kept up to date but for Ruby on Rails developers this is doubly true. Enter Ruby Toolbox, a website tracking Rails plugin popularity on Github. Read the rest of this entry »
Website Checklist
Posted by jdempcy in Uncategorized on July 13, 2009
As a web developer, whenever you take on new projects you’ll often find yourself doing the same tasks, over and over. I find it convenient to keep a checklist as a template that I use for new projects. Read the rest of this entry »
Setting Up a Windows Vista Development Environment
Posted by jdempcy in JavaScript, jQuery on July 13, 2009
I recently purchased a new computer and was faced with the task of setting up a fresh installation of Windows Vista with all of the web development goodies I’ve come to know and love.
Here’s a walkthrough for what I did to get set up, starting from square one. This is literally everything I did and installed from when I was first able to access the desktop after a fresh install.
jQuery normal text to seo urls in real time
Posted by grandecomplex in SEO, jQuery on July 13, 2009

This is a way to mindlessly type in text to receive it an url in seo-friendly format.
It is also a good lesson on how jQuery can instantly return text and the use of simple regex.
Making IE have more than one background per element
Posted by grandecomplex in CSS on July 13, 2009
Calling Any JS Lightbox from Flash using jQuery
Posted by grandecomplex in JavaScript, jQuery on July 13, 2009

Thanks to Flash’s ExternalInferface’s API you can call JavaScript or receive a callback from JavaScript using Flash. In this example I will show you how to call any Lightbox that is in JavaScript from Flash.
import flash.external.ExternalInterface;
button.addEventListener(MouseEvent.CLICK, external, false, 0, true);
function external(evt:MouseEvent):void {
ExternalInterface.call("external", "lightbox/photos/image1.jpg");
}
function external(path) { // pass in the correct path to the function so we only need one for infinite amount of calls from flash
// if the lightbox does not exist we will make it
if ($('a#lightbox').length == 0) {
$("body").append("calling js lightbox from flash");
$('a#lightbox').lightBox();
// if it already exists but the path is different we will set the new path
} else if ($('a#lightbox').attr("href") != path) {
$('a#lightbox').attr("href", path);
}
// now we will simulate the click here.
$('a#lightbox').trigger("click");
}
CSS Naming Convention Best Practices
Posted by grandecomplex in CSS on July 13, 2009
When building components, it is important to follow a set of guidelines when naming your IDs and classes. This article will explore best practices in choosing CSS names.Adding Share on Facebook Links
Posted by grandecomplex in JavaScript on July 13, 2009
You know those Facebook links that allow you to post directly on Facebook? They are both highly useful and easy to add to a site. And, they are incredibly easy to add! Read the rest of this entry »
Stripping out HTML Tags in jQuery
Posted by grandecomplex in jQuery on July 13, 2009
One of the useful features most JavaScript libraries offer is the ability to strip out HTML tags from strings, leaving only the text. This is useful because you may have user input that you need to "sanitize" by removing potentially malicious HTML. Read the rest of this entry »

Activity
Geir Freysson
Andrew DiFiore
zeming
Arun, Neil, shashwat
Eric, Fernando Zanatta, Jörn Zaefferer