Displaying 2 results from an estimated 2 matches for "_house".
Did you mean:
house
2006 Mar 30
11
Illegal char \002? Need to restart Rails to see changes?
...I edit it.
Here''s an example, from a change to a partial template. It was working
properly, and the only change I made was to add "<p>Hi</p>" to the top.
Then I refreshed the page in the browser and got this:
SyntaxError in Houses#list
Showing app/views/houses/_house.rhtml where line #3 raised:
compile error
./script/../config/../app/views/houses/_house.rhtml:3: parse error,
unexpected $, expecting kEND
_erbout.concat " <h3 class=\"house_title\">"
^
Extracted source (around line #3):
1:...
2006 Feb 06
7
Delaying initialization of associations until first access
Guys,
Say I have the following:
-----
class Person < ActiveRecord::Base
has_one :house
end
class House < ActiveRecord::Base
belongs_to :person
attr_accessor :color
end
-----
Then I have the following code:
-----
john = Person.new
john.house.color = "Blue"
john.save
-----
What I would like to have happen, is that on first call to john.house, if
house hadn''t been