Help in my controller Ad layout i have a ‘render partial’
that partial will iterate through an array of data from the db, ok
but where should i put this line in my Ad controller?
@ad = Ad.find_all_by_user_id(sessions[:user])
( since there’s no particular method, which would’ve been basic and
i’ve tried putting it under the index method, and it works except for
the first time the page is called, there is a nil…
i’ve tried putting it under ‘initalize’, and that messes the session up.
and also tried point blank under the class, and no hope…