'Converts an underscored or CamelCase word into a English sentence.
The titleize function converts text like "WelcomePage",
"welcome_page" or  "welcome page" to this "Welcome Page".
If second parameter is set to \'first\' it will only
capitalize the first character of the title.'

def titleize(self, word, uppercase=''):

    if (uppercase == 'first'):
        return self.humanize(self.underscore(word)).capitalize()
    else:
        return self.humanize(self.underscore(word)).title()
