search for: links_control

Displaying 4 results from an estimated 4 matches for "links_control".

2006 Jun 25
2
how to write the codes in view?(newbie question)
Hi. I have two tables and want to join them. <genres> id genre_name genre_order <links> id genre_id name symbol url order display etc The code of links_Controller is like below. def list @links = Genre.find(:all,:include => :link) end Below is the mysql log. SELECT genres.`id` AS t0_r0, genres.`genre_n ame` AS t0_r1, genres.`genre_order` AS t0_r2, links.`id` AS t1_r0, links.`genre_ id` AS t1_r1, links.`name` AS t1_r2, links.`symbol` AS t1_r3, links....
2006 Jul 16
6
How to access element attributes using RJS?
For example, in the following block: page.select(''.foo'').each do |element| ... end How would I access, just for example, the id attribute of each element in the collection? I''ve randomly tried element.id and element.attributes[''id''], but neither of those has worked. I''ve also been unsuccessful in finding any documentation on this, but it
2007 Jun 18
4
polymorphic validation
Hello I have 2 models. link.rb has_many :categories, :as => :categorized validates_presence_of :name, :url, :created_at, :category category.rb belongs_to :categorized, :polymorphic => true validates_presence_of :name Everything seems to work. I select my category from a select tag. The problem is i don''t know how to validate if category is for example empty (nothing in a
2007 Mar 28
7
Newbie problem on production server
.../vendor/plugins/acts_as_ferret/lib/class_methods.rb:134:in `ar_find_by_contents'' /vendor/plugins/acts_as_ferret/lib/class_methods.rb:128:in `find_records_lazy_or_not'' /vendor/plugins/acts_as_ferret/lib/class_methods.rb:54:in `find_by_contents'' /app/controllers/links_controller.rb:11:in `results'' -- Posted via http://www.ruby-forum.com/.