Ruby on Rails: Change class name into human readable string
line_item = LineItem.new puts line_item.class.name.underscore.humanize.lowcase #spits out "line item"
DZone Snippets > thechrisoshow
12382 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
Chris O'Sullivan http://www.thechrisoshow.com
line_item = LineItem.new puts line_item.class.name.underscore.humanize.lowcase #spits out "line item"
select so.name as 'storProc' from sysobjects so join syscomments sc on so.id=sc.id where so.type='P' and sc.[text] like '%BIT_YOU_WANT_TO_FIND%'