Skip to content

Instantly share code, notes, and snippets.

@gugod
Created January 30, 2009 15:24
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save gugod/55107 to your computer and use it in GitHub Desktop.
Save gugod/55107 to your computer and use it in GitHub Desktop.
# Usage: grid_row(3 => "user/login", 10 => "welcome/content", 3 => "common/ads")
def grid_row(*args)
out = ""
while(args.length > 0) {
width = args.shift
partial = args.shift
out += "<div class=\"grid_#{width}\">#{render :partial => partial}</div>"
}
return out
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment