title: string manipulation with ruby on rails
body: <p>I have been trying to manipulate a string ( like substring function in java)
  so, most of the on-line guides point towards the following options :</p>
  
  <pre><code>   str.split("A").first
     str[0...15]
     str.from(0).to(15)
  </code></pre>
  
  <p>but whenever I use any of the above I get this error: </p>
  
  <p>NoMethodError </p>
  
  <pre><code>1) undefined method 'split'
  
  2) undefined method '[]'
  
  3) undefined method 'from'
  </code></pre>
  
  <p>I guess there is some lib or something I am supposed to use. Any help towards the right direction would be appreciated.</p>
  
  <p>Note : using ruby 2.0 and rails 4</p>