Search Result

Collapse
8 results in 0.0038 seconds.
Keywords
Members
Tags
rails
  •  

  • Error of "undefined method `each' for #<Pictograph:0x927dea0>"

    hi all,

    I have an error "undefined method `each' for #<Picture:0x927 dea0>"
    what is that mean?

    in my view
    Code:
    <% @user.each do |p| %>
    <%= p.image %>
    <% end %>

    in controller
    Code:
               @user=picture.all(
    		 :joins => :culture,
                      :conditions => (Album.joins(:description))).first
    ...
    See more | Go to post

  • Wiinie
    started a topic error of Unknown key(s): #<Picture:0xa4d673c>
    in Ruby

    error of Unknown key(s): #<Picture:0xa4d673c>

    i have this error .. when i try to take a value from other table. plus, in the terminal, it shows "select "users".* from users.
    picture - album one-to-many relationship

    Code:
    def self.pic
    Picture.all(joins => :album, :select => "album.image" )
    end
    Code:
    
    
    Code:
    //controller
      def show
           @user= User.all
           @me
    ...
    See more | Go to post

  • Wiinie
    started a topic taking value from DB in rails
    in Ruby

    taking value from DB in rails

    Hi, I am new in Rails, and now i have a problem to take data from one of tables in DB

    This is my code:

    Code:
    //user model
    belongs_to season
    belongs_to album
    has_many albums
    
    #### ----->
    def get_pic
    
    @pic = Picture.where(:album_id => 'Album.album_id' ,
          user.where(:culture_id => 'Culture.culture_id')).first
    
    end
    ### ----->
    ...
    See more | Go to post

  • Wiinie
    started a topic Print a whole page and print div content

    Print a whole page and print div content

    Hi, all

    I am new, I am using rails to write the application... and now I want to make a function for print the specific div in the page.

    What can I do with this?

    Please give me some advice.

    I did try to use
    Code:
      <a href="#" onclick="window.print();return false;"><img src ="http://png.findicons.com/files/icons/61/dragon_soft/512/printer.png" width="20"
    ...
    See more | Go to post
    Last edited by Frinavale; Jun 7 '11, 05:07 PM. Reason: Fixed code tags. Corrected grammar and formatted the question to use proper English.

  • Error of uninitialized constant LanguageController::Languages

    Hi,

    I am a new comer on Ruby on Rails
    I have no idea what i have made with this error
    Code:
    def new
     @language = Language.new
    end
    Code:
    rails generate model title:string body:string

    can anyone help me
    thanks
    See more | Go to post

  • Updated my rails 2.3.2 now getting > undefined method `inject' for true:TrueClass

    I just update my RubyGems and Rails. I am working on Rails 2.3.2 and everything was working prior to this update.

    Now I am getting the following error:

    undefined method `inject' for true:TrueClass

    I have no idea what this means or where it is coming from. It does not seem to matter what I delete or which page I try to load on the website.

    The full trace is as follows:

    /Users/mitch/.gem/ruby/1.8/gems/activesupport-2.3.2/lib/active_support/vendor/i18n-0.1.3/lib/i18n/backend/simple.rb:206:i n...
    See more | Go to post

  • nesko
    started a topic working under webrick but not under passenger
    in Ruby

    working under webrick but not under passenger

    Hi!

    I have just added login feature to my rails application by following the
    instructions from "Agile Web Development with Rails" but now I am getting
    strange error (looks to me like some kind of routing problem) under the
    passenger/apache. It is working fine under webrick.

    The error is:
    500 Internal Server Error
    The server encountered an internal error or misconfiguratio n...
    See more | Go to post

  • niharpophale
    started a topic Ajax not working fine with IE6
    in Ruby

    Ajax not working fine with IE6

    Hi to all,

    I am posting for the first time in this forum.....
    I have been using ruby on rails from quite a few months now, I have come across this problem.....
    When I am using link_to_remote, the page is breaking in IE6 but the same code works well in IE7 and Mozilla. I am now very confused as to how to solve this problem....

    Did someone already encountered the same problem??
    Please help me with...
    See more | Go to post
Working...