features:
- converts every improper character to a hyphen
- returns a lowercase string
I POSTED AN EVEN BETTER METHOD ON MY BLOG: http://tinyurl.com/2vurbq
def create_callname (title) title.downcase.gsub(/[^a-z0-9]+/i, '-') end
11304 users tagging and storing useful source code snippets
Snippets is a public source code repository. Easily build up your personal collection of code snippets, categorize them with tags / keywords, and share them with the world
def create_callname (title) title.downcase.gsub(/[^a-z0-9]+/i, '-') end
You need to create an account or log in to post comments to this site.