<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DZone Snippets: helper code</title>
    <link>http://snippets.dzone.com/posts</link>
    <pubDate>Fri, 25 Jul 2008 08:32:47 GMT</pubDate>
    <description>DZone Snippets: helper code</description>
    <item>
      <title>Initial caps with ruby on rails</title>
      <link>http://snippets.dzone.com/posts/show/4972</link>
      <description>&lt;code&gt;&lt;br /&gt;class String&lt;br /&gt;  # unicode_str.initial_caps =&gt; new_str&lt;br /&gt;  # returns a copy of a string with initial capitals&lt;br /&gt;  # "Jules-&#201;douard".initial_caps =&gt; "J.&#201;."&lt;br /&gt;  def initial_caps&lt;br /&gt;    self.tr('-', ' ').split(' ').map { |word| word.chars.first.upcase.to_s + "." }.join&lt;br /&gt;  end&lt;br /&gt;end&lt;br /&gt;&lt;/code&gt;</description>
      <pubDate>Thu, 10 Jan 2008 12:41:22 GMT</pubDate>
      <guid>http://snippets.dzone.com/posts/show/4972</guid>
      <author>jerome ()</author>
    </item>
  </channel>
</rss>
