Sign In/My Account | View Cart  

advertisement

AddThis Social Bookmark Button

Article:
  Rolling with Ruby on Rails Revisited, Part 2
Subject:   Stuck in the first server running in page 2
Date:   2008-05-13 04:09:59
From:   Rogare
I am in page 2 after changing the @recipe.date = Time.now thing.
I opened my server (ruby script\server) and entered 127.0.0.1:3000/recipes.
I clicked on the "New Recipe" and got this errors:
compile error
C:/cookbook2/app/views/recipes/new.html.erb:10: parse error, unexpected tLBRACE, expecting ')'
{|c| [c.name, c.id] }) ).to_s); _erbout.concat "\n"
^
C:/cookbook2/app/views/recipes/new.html.erb:10: parse error, unexpected '}', expecting ')'
{|c| [c.name, c.id] }) ).to_s); _erbout.concat "\n"



I am using Rails 2.0.2 and Ruby 1.8.5 on Windows XP.

Full Threads Oldest First

Showing messages 1 through 2 of 2.

  • Stuck in the first server running in page 2
    2008-05-13 08:42:26  Bill Walton | [View]

    Hi Rogare,

    It looks like you're missing a closing parenthesis ')' on line 10 of new.html.erb.

    One note. As it says at the top of the article. The tutorial is not updated for Rails 2.x. You may encounter problems related to the differences between 1.2.x and 2.x. Look through the posts here and you'll find answers.

    Best regards,
    Bill
    • Stuck in the first server running in page 2
      2008-05-13 11:17:16  Rogare [View]

      Was silly problem. There was a line break after the .collect . Fixed and working.