# Rails

**URL:** https://www.ruby-forum.com/c/ruby-on-rails/6.md?page=1583

[Latest](https://www.ruby-forum.com/latest.md) · [Categories](https://www.ruby-forum.com/categories.md) · [Tags](https://www.ruby-forum.com/tags.md)

**Page:** 1584

---

## [Combobox and m:n relation](https://www.ruby-forum.com/t/combobox-and-m-n-relation/123165)

<div class="topic-metadata">

**Author:** [@luixx](https://www.ruby-forum.com/u/luixx)\
**Replies:** 0\
**Last updated:** [December 14, 2007, 4:16pm UTC](https://www.ruby-forum.com/t/combobox-and-m-n-relation/123165 "2007-12-14T16:16:43Z")

</div>

Hi, i have a project and a task. both have a m:n relation to each other. I made a scaffolding and want to insert a combobox in the task new view Code : ruby - fold - unfold \<label for="project\_name\_ger"\>Poject\</labe…

---

## [What's the last version of Rails that lets you](https://www.ruby-forum.com/t/whats-the-last-version-of-rails-that-lets-you/123109)

<div class="topic-metadata">

**Author:** [@chriscole](https://www.ruby-forum.com/u/chriscole)\
**Replies:** 2\
**Last updated:** [December 14, 2007, 4:07pm UTC](https://www.ruby-forum.com/t/whats-the-last-version-of-rails-that-lets-you/123109 "2007-12-14T16:07:55Z")

</div>

What’s the last version of Rails that lets you do this in your controller. scaffold :post I need it for a set of video tutorials I purchased from lynda.com Thanks!

---

## [Upgrading rails](https://www.ruby-forum.com/t/upgrading-rails/123162)

<div class="topic-metadata">

**Author:** [@ruby\_tl](https://www.ruby-forum.com/u/ruby_tl)\
**Replies:** 1\
**Last updated:** [December 14, 2007, 3:59pm UTC](https://www.ruby-forum.com/t/upgrading-rails/123162 "2007-12-14T15:59:43Z")

</div>

Hi ia m working on a project carried out using an older version of rails 1.2.4 or 5. And I want to upgrade it to 1.2.6. Can you tell me the command to upgrade or install that version. I am not sure if this is corre…

---

## [Extracting code to a module, failed](https://www.ruby-forum.com/t/extracting-code-to-a-module-failed/123163)

<div class="topic-metadata">

**Author:** [@harm](https://www.ruby-forum.com/u/harm)\
**Replies:** 0\
**Last updated:** [December 14, 2007, 3:53pm UTC](https://www.ruby-forum.com/t/extracting-code-to-a-module-failed/123163 "2007-12-14T15:53:15Z")

</div>

Dear all, I wrote a piece of code with which I can copy models and their associated models as new database entries. Now I want to extract this code so I can easily use it in other projects/models. What I have: class…

---

## [Restful\_authentication + nested resources =\> failed to authenticate](https://www.ruby-forum.com/t/restful-authentication-nested-resources-failed-to-authenticate/123157)

<div class="topic-metadata">

**Author:** [@Kei\_Simone](https://www.ruby-forum.com/u/Kei_Simone)\
**Replies:** 2\
**Last updated:** [December 14, 2007, 3:43pm UTC](https://www.ruby-forum.com/t/restful-authentication-nested-resources-failed-to-authenticate/123157 "2007-12-14T15:43:50Z")

</div>

To all: hi, i used rails 1.2.6 + restful\_authentication plugin #base\_url base = ‘/v1’ map.resources :users, :path\_prefix =\> base map.resources :users do |users| users.resources :orders, :path\_prefix =\> ‘/v1/users/…

---

## [Migrations with no ID](https://www.ruby-forum.com/t/migrations-with-no-id/123159)

<div class="topic-metadata">

**Author:** [@damaris](https://www.ruby-forum.com/u/damaris)\
**Replies:** 2\
**Last updated:** [December 14, 2007, 2:59pm UTC](https://www.ruby-forum.com/t/migrations-with-no-id/123159 "2007-12-14T14:59:06Z")

</div>

Hi there, I’m using Migrations to define my db schema. However, I have a table that mustn’t have an ID. Migrations always add them automatically; is there any way to tell the “create\_table” that I donÂ¡t need the “id” …

---

## [Using the session to pass a value from form to controller](https://www.ruby-forum.com/t/using-the-session-to-pass-a-value-from-form-to-controller/123150)

<div class="topic-metadata">

**Author:** [@cmaxvv](https://www.ruby-forum.com/u/cmaxvv)\
**Replies:** 3\
**Last updated:** [December 14, 2007, 1:46pm UTC](https://www.ruby-forum.com/t/using-the-session-to-pass-a-value-from-form-to-controller/123150 "2007-12-14T13:46:56Z")

</div>

I have a form in which a bunch of new users can be created with the same password if desired. I’m trying to write the password into the session and pull it out in the controller (besides avoiding putting it into para…

---

## [Storing a hash in the data base](https://www.ruby-forum.com/t/storing-a-hash-in-the-data-base/123019)

<div class="topic-metadata">

**Author:** [@gadys](https://www.ruby-forum.com/u/gadys)\
**Replies:** 4\
**Last updated:** [December 14, 2007, 1:38pm UTC](https://www.ruby-forum.com/t/storing-a-hash-in-the-data-base/123019 "2007-12-14T13:38:04Z")

</div>

Hi I’m new to rails and I want to create an object named element with can hold sevral properties names and values. for example : e = Element.create() e.add(:name =\> “x”, :value =\> 800) e.add(:name =\> “y”, :value =\> …

---

## [How to create yaml](https://www.ruby-forum.com/t/how-to-create-yaml/123145)

<div class="topic-metadata">

**Author:** [@manjularaj](https://www.ruby-forum.com/u/manjularaj)\
**Replies:** 1\
**Last updated:** [December 14, 2007, 1:25pm UTC](https://www.ruby-forum.com/t/how-to-create-yaml/123145 "2007-12-14T13:25:46Z")

</div>

Hi, How can i create yml file to dynamically store data instead of storing it in db. I don’t want to create yml file for the purpose of testing as it is done in fixtures. What i want to do is to store some of my data …

---

## [File upload issue](https://www.ruby-forum.com/t/file-upload-issue/123134)

<div class="topic-metadata">

**Author:** [@deliak](https://www.ruby-forum.com/u/deliak)\
**Replies:** 4\
**Last updated:** [December 14, 2007, 1:24pm UTC](https://www.ruby-forum.com/t/file-upload-issue/123134 "2007-12-14T13:24:07Z")

</div>

Hi all, I’m running my rails app with dispatch.fcgi && lighttpd in a environment with memory issues(but no disk space issues). Whenever I try to upload a file via http (simple multipart form with input type file) whi…

---

## [Tricky helper question](https://www.ruby-forum.com/t/tricky-helper-question/123140)

<div class="topic-metadata">

**Author:** [@silvertab](https://www.ruby-forum.com/u/silvertab)\
**Replies:** 2\
**Last updated:** [December 14, 2007, 11:57am UTC](https://www.ruby-forum.com/t/tricky-helper-question/123140 "2007-12-14T11:57:14Z")

</div>

I am trying to code a helper that will print a list of threaded forums, as options of a select field…a forum has a parent\_id (which is another forum’s id) or 0, meaning it is a “root level” forum… For example, the res…

---

## [How to get the errors on Controlers](https://www.ruby-forum.com/t/how-to-get-the-errors-on-controlers/121986)

<div class="topic-metadata">

**Author:** [@Anson](https://www.ruby-forum.com/u/Anson)\
**Replies:** 3\
**Last updated:** [December 14, 2007, 10:59am UTC](https://www.ruby-forum.com/t/how-to-get-the-errors-on-controlers/121986 "2007-12-14T10:59:57Z")

</div>

Now i want to get the errors of Model(like some error of validate\_xxx\_of ) How can i do? it seems that no error object on Controllers by API docments, Thanks.

---

## [No such file to load â€” ubygems (LoadError)](https://www.ruby-forum.com/t/no-such-file-to-load-a-ubygems-loaderror/123031)

<div class="topic-metadata">

**Author:** [@cmaxvv](https://www.ruby-forum.com/u/cmaxvv)\
**Replies:** 3\
**Last updated:** [December 14, 2007, 10:57am UTC](https://www.ruby-forum.com/t/no-such-file-to-load-a-ubygems-loaderror/123031 "2007-12-14T10:57:54Z")

</div>

All of a sudden, i’m getting this error when trying to launch the console - no such file to load â€” ubygems (LoadError) I’m using 1.2.3 as my base rails install and i also get the same problem in a project frozen to…

---

## [Image upload using ajax](https://www.ruby-forum.com/t/image-upload-using-ajax/122626)

<div class="topic-metadata">

**Author:** [@koli](https://www.ruby-forum.com/u/koli)\
**Replies:** 11\
**Last updated:** [December 14, 2007, 10:20am UTC](https://www.ruby-forum.com/t/image-upload-using-ajax/122626 "2007-12-14T10:20:50Z")

</div>

can anybody let me know how to do image upload using file\_column and ajax???

---

## [Advice on performance concerns (MySQL / Number of rows)](https://www.ruby-forum.com/t/advice-on-performance-concerns-mysql-number-of-rows/123115)

<div class="topic-metadata">

**Author:** [@casper\_the\_ghost](https://www.ruby-forum.com/u/casper_the_ghost)\
**Replies:** 2\
**Last updated:** [December 14, 2007, 9:45am UTC](https://www.ruby-forum.com/t/advice-on-performance-concerns-mysql-number-of-rows/123115 "2007-12-14T09:45:21Z")

</div>

Hi all, I’m developing a web app that I intend on trying to sell as SaaS (Software as a Service (ie Basecamp)). The first thought on my head would be to use one single database, and create columns to indicate which…

---

## [Large file upload issue](https://www.ruby-forum.com/t/large-file-upload-issue/123133)

<div class="topic-metadata">

**Author:** [@deliak](https://www.ruby-forum.com/u/deliak)\
**Replies:** 0\
**Last updated:** [December 14, 2007, 9:32am UTC](https://www.ruby-forum.com/t/large-file-upload-issue/123133 "2007-12-14T09:32:36Z")

</div>

Hi all, I’m using dispatch.fcgi && lighttpd in a environment with memory issues. Whenever I try to upload a file which size exceeds the memory limits, lighttpd process grows till it fills all the available memory and…

---

## [Cart problem](https://www.ruby-forum.com/t/cart-problem/104708)

<div class="topic-metadata">

**Author:** [@pabloz](https://www.ruby-forum.com/u/pabloz)\
**Replies:** 2\
**Last updated:** [December 14, 2007, 8:33am UTC](https://www.ruby-forum.com/t/cart-problem/104708 "2007-12-14T08:33:41Z")

</div>

Hi I have a simple shopping cart. The whole cart is in a form so i can update the quantity, this works fine. How should i make the “delete\_item” to work? I know i shouldn’t use normal links, and i cant have nested fo…

---

## [Rails & Ajax : Updating a list from the top](https://www.ruby-forum.com/t/rails-ajax-updating-a-list-from-the-top/123081)

<div class="topic-metadata">

**Author:** [@julien51](https://www.ruby-forum.com/u/julien51)\
**Replies:** 9\
**Last updated:** [December 14, 2007, 7:57am UTC](https://www.ruby-forum.com/t/rails-ajax-updating-a-list-from-the-top/123081 "2007-12-14T07:57:27Z")

</div>

Hi! I am newbie in AJAX, RJS just a beginer in Rails. Anyway, here is my problem : I am bulding an app that will display a list of messages. The last messages appear at the top of the list. For now, it’s static, the …

---

## ["Multiple default values" with Rails migration](https://www.ruby-forum.com/t/multiple-default-values-with-rails-migration/123125)

<div class="topic-metadata">

**Author:** [@chirag](https://www.ruby-forum.com/u/chirag)\
**Replies:** 0\
**Last updated:** [December 14, 2007, 7:43am UTC](https://www.ruby-forum.com/t/multiple-default-values-with-rails-migration/123125 "2007-12-14T07:43:32Z")

</div>

I am running the following migration with PostgreSQL 8.2.5. It works fine on my Windows machine, but gives me the below error on Linux CentOS 4.3. Any ideas? Thanks, Chirag class CreateUsers \< ActiveRecord::Migration …

---

## [Rails complaining about {:method=\>:get} on an AJAX call](https://www.ruby-forum.com/t/rails-complaining-about-method-get-on-an-ajax-call/123119)

<div class="topic-metadata">

**Author:** [@unknown](https://www.ruby-forum.com/u/unknown)\
**Replies:** 5\
**Last updated:** [December 14, 2007, 7:23am UTC](https://www.ruby-forum.com/t/rails-complaining-about-method-get-on-an-ajax-call/123119 "2007-12-14T07:23:40Z")

</div>

Hello guys, I hope you can point me in the right direction. I just moved to Rails 2.0 and I’m having some problems. I’m using ExtJS (excellent widget library btw), to make my application. Right now I’m testing a log…

---

## [Nested Resources And Creating URL Problemos](https://www.ruby-forum.com/t/nested-resources-and-creating-url-problemos/123112)

<div class="topic-metadata">

**Author:** [@johnk](https://www.ruby-forum.com/u/johnk)\
**Replies:** 3\
**Last updated:** [December 14, 2007, 5:15am UTC](https://www.ruby-forum.com/t/nested-resources-and-creating-url-problemos/123112 "2007-12-14T05:15:03Z")

</div>

I am doing the following: link\_to “delete my avatar”, user\_pictures\_path(:user\_id =\> @user, :id =\> @ user.pictures.last), :method =\> :delete and it is creating the following link: http://127.0.0.1:3000/users/4/pictu…

---

## [Sorting the children of an object](https://www.ruby-forum.com/t/sorting-the-children-of-an-object/123029)

<div class="topic-metadata">

**Author:** [@gadys](https://www.ruby-forum.com/u/gadys)\
**Replies:** 5\
**Last updated:** [December 14, 2007, 4:31am UTC](https://www.ruby-forum.com/t/sorting-the-children-of-an-object/123029 "2007-12-14T04:31:11Z")

</div>

Hi another quick question. i have a relationship “areas has\_many elements” (elements acts\_as\_list) i want to retrive those elements ordered by element.position elements = area.elements elements.each do |element| is…

---

## [Rails2.0 scaffold generator](https://www.ruby-forum.com/t/rails2-0-scaffold-generator/123107)

<div class="topic-metadata">

**Author:** [@rails](https://www.ruby-forum.com/u/rails)\
**Replies:** 2\
**Last updated:** [December 14, 2007, 3:59am UTC](https://www.ruby-forum.com/t/rails2-0-scaffold-generator/123107 "2007-12-14T03:59:38Z")

</div>

In version rails1.2, we can use script/generate scaffold modelname controllername, but in version 2, the scafflod generator only receive the model parameter in this way: script/generate scaffold modelname. Now, i want…

---

## [Calling GC.start with attachment\_fu and RMagick -- where or if?](https://www.ruby-forum.com/t/calling-gc-start-with-attachment-fu-and-rmagick-where-or-if/123110)

<div class="topic-metadata">

**Author:** [@skaufman](https://www.ruby-forum.com/u/skaufman)\
**Replies:** 0\
**Last updated:** [December 14, 2007, 3:42am UTC](https://www.ruby-forum.com/t/calling-gc-start-with-attachment-fu-and-rmagick-where-or-if/123110 "2007-12-14T03:42:42Z")

</div>

RMagick (and ImageMagick) have been criticized for memory leaks, though the problem is avoidable by timely garbage collection – see this thread: http://groups.google.com/group/rubyonrails-talk/browse\_thread/thread/ede…

---

## [\[ANN\] async-observer rails plugin](https://www.ruby-forum.com/t/ann-async-observer-rails-plugin/123111)

<div class="topic-metadata">

**Author:** [@krat](https://www.ruby-forum.com/u/krat)\
**Replies:** 0\
**Last updated:** [December 14, 2007, 3:27am UTC](https://www.ruby-forum.com/t/ann-async-observer-rails-plugin/123111 "2007-12-14T03:27:57Z")

</div>

I’m pleased to announce the existence of async-observer. This is the very first public release. In the future I’ll confine announcements to the beanstalk-talk mailing list. WHAT IS ASYNC OBSERVER? Async Observer is a…

---

## [Datetime\_select and seconds?](https://www.ruby-forum.com/t/datetime-select-and-seconds/123077)

<div class="topic-metadata">

**Author:** [@pete](https://www.ruby-forum.com/u/pete)\
**Replies:** 1\
**Last updated:** [December 14, 2007, 2:33am UTC](https://www.ruby-forum.com/t/datetime-select-and-seconds/123077 "2007-12-14T02:33:37Z")

</div>

Is it possible to add seconds to the datetime\_select form helper? I noticed this was posted before but never answered. Thanks!

---

## [Newbie qusetion, about unicode](https://www.ruby-forum.com/t/newbie-qusetion-about-unicode/123034)

<div class="topic-metadata">

**Author:** [@xpol](https://www.ruby-forum.com/u/xpol)\
**Replies:** 2\
**Last updated:** [December 14, 2007, 2:28am UTC](https://www.ruby-forum.com/t/newbie-qusetion-about-unicode/123034 "2007-12-14T02:28:22Z")

</div>

Hello, I’m a beginner to Rails. I has a problem about unicode when I tried some example code like below: say\_controller.rb: class SayController \< ApplicationController def list @files = Dir.glob(’\*’) end end appl…

---

## [Time.advance( :minutes=\> x ) question](https://www.ruby-forum.com/t/time-advance-minutes-x-question/123083)

<div class="topic-metadata">

**Author:** [@mrkohrea](https://www.ruby-forum.com/u/mrkohrea)\
**Replies:** 1\
**Last updated:** [December 14, 2007, 2:01am UTC](https://www.ruby-forum.com/t/time-advance-minutes-x-question/123083 "2007-12-14T02:01:27Z")

</div>

Hello all-I’m a new Ruby developer(but longtime java developer), and I’m having trouble getting Time to work for me. With a ‘base’ date as Monday of this week: Time.now.beginning\_of\_week.asctime =\> “Mon Dec 10 00:00:…

---

## [RSPEC: Looking for some clarification](https://www.ruby-forum.com/t/rspec-looking-for-some-clarification/123068)

<div class="topic-metadata">

**Author:** [@akv292](https://www.ruby-forum.com/u/akv292)\
**Replies:** 1\
**Last updated:** [December 14, 2007, 1:54am UTC](https://www.ruby-forum.com/t/rspec-looking-for-some-clarification/123068 "2007-12-14T01:54:25Z")

</div>

So, I am new to testing and am a fan of the RSPEC framework, so far. There are still a few things about mocking/stubbing that I am unclear on. I am using the line… Project.should\_receive(:find).with(@params\[:id\]).and…

---

## [Why did Rails get created?](https://www.ruby-forum.com/t/why-did-rails-get-created/123071)

<div class="topic-metadata">

**Author:** [@desbest](https://www.ruby-forum.com/u/desbest)\
**Replies:** 3\
**Last updated:** [December 14, 2007, 1:49am UTC](https://www.ruby-forum.com/t/why-did-rails-get-created/123071 "2007-12-14T01:49:44Z")

</div>

Why did rails get created? The creator (David Heinemeiner Hanson) already knows php. (http:// Getting Real)

[Previous page](https://www.ruby-forum.com/c/ruby-on-rails/6.md?page=1582)

[Next page](https://www.ruby-forum.com/c/ruby-on-rails/6.md?page=1584)
