Hi.<br><br>When I read Dave and Davids excellent book &quot;Agile Web Development with Rails&quot; the first time, I was particularly impressed with the following statement:<br><div style="margin-left: 40px;">1.day.from_now
<br></div><br>It was used in a test class to set the date of tomorrow dynamically. Since it was enclosed in in ERb tags, I assumed this was a normal ruby statement, but when I tried it in my irb, i get the following error:
<br><div style="margin-left: 40px;">irb(main):007:0&gt; 1.day.from_now<br>NoMethodError: undefined method `day' for 1:Fixnum<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; from (irb):7<br>irb(main):008:0&gt;<br></div><br>I would be abliged if someone could explain to me how this works in ERb and not in standard ruby? Have I missed something fundamental here?
<br><br>Best regards,<br>Jørn Ølmheim<br>www: <a href="http://www.olmheim.com">http://www.olmheim.com</a><br>blog: <a href="http://blog.olmheim.com">http://blog.olmheim.com</a><br>