Hi all,
First of all I will describe the setup and then ask the question.
I have created a test website which is running on Apache 2.2 on Windows and uses Ruby on Rails 1.8 ( this older version is a requirement, but I think irrelevant to this question ) for a couple of dynamic pages, the rest of the pages are static.
The main website runs in "C:/MyRubyWebsite" through Ruby on Rails with 2 pages,...
Search Result
Collapse
11 results in 0.0031 seconds.
Keywords
Members
Tags
-
Secure website on Windows Apache which overrides Ruby proxy
-
Ruby: airline reservation (arrays)
I cannot, for the life of me and my goldfish, get this code to work for an assignment. I cannot make it change the array location to a 1 to make it "filled" by a passenger. I do .inspect at the end of the script and the array is just full of 0's (like how it is already set up), nothing I have tried will get the array to reflect what I want it to do.
What am I doing wrong?
The boolean array is called $assignment.... -
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 -
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 -
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 ### -----> -
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"
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 -
what is the error of "uninitialized constant Object::Person (NameError)"?
Hi all,
I am new bird using Ruby, I just occur the problem "uninitiali zed constant Object::Person (NameError)"
can any experts help me?
my code is
...Code:class Person def initialize(fname, lname) @fname = fname @lname = lname end def to_s "Person: #@fname #@lname" end end person = Person.new("Yen", -
How to connect to Mysql & Query for Database Tables?
Hi Guys,
Ruby imposes several way of connecting to Mysql (DBI,activereco rd..) Database using ruby code. Let me know if anybody knows how to connect to mysql the easiest way.
I am getting all sorts of error trying to connect to mysql. I am using Windows XP OS.
Hope to hear from you guys soon!!
Cheers -
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... -
Metaprogramming in Ruby: class_eval vs. instance_eval
I'm using Ruby 1.8.6 btw.
For the longest time today (it seems) I've been trying to understand exactly the operating difference between class_eval and instance_eval. There are some obvious differences I'm perfectly aware of (e.g. class_eval is only on Class objects), but the reality is that some irb tinkering has left me more confused than ever. Given the following:
...Code:class Foo # could be any class