# Rails

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

[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:** 1798

---

## [Mongrel missing](https://www.ruby-forum.com/t/mongrel-missing/109358)

<div class="topic-metadata">

**Author:** [@casper\_the\_ghost](https://www.ruby-forum.com/u/casper_the_ghost)\
**Replies:** 2\
**Last updated:** [July 13, 2007, 7:08pm UTC](https://www.ruby-forum.com/t/mongrel-missing/109358 "2007-07-13T19:08:11Z")

</div>

Hi! I’m trying to deploy my application, but running into a problem. I’ve deployed it before and saw that there were files in the ./script directory that do not exist anymore. Such files are mongrel and nginx. I w…

---

## [Validation performed on has\_many associations before updatin](https://www.ruby-forum.com/t/validation-performed-on-has-many-associations-before-updatin/109315)

<div class="topic-metadata">

**Author:** [@elliterate](https://www.ruby-forum.com/u/elliterate)\
**Replies:** 3\
**Last updated:** [July 13, 2007, 6:32pm UTC](https://www.ruby-forum.com/t/validation-performed-on-has-many-associations-before-updatin/109315 "2007-07-13T18:32:04Z")

</div>

Hi, I have a Campaign model which has\_many :condition\_sets. The ConditionSet belongs\_to :campaign and also validates\_presence\_of :campaign\_id Now, If I… c = Campaign.new s = c.condition\_sets.build c.save! Active…

---

## [Upgrade issue](https://www.ruby-forum.com/t/upgrade-issue/109349)

<div class="topic-metadata">

**Author:** [@newbie](https://www.ruby-forum.com/u/newbie)\
**Replies:** 1\
**Last updated:** [July 13, 2007, 6:27pm UTC](https://www.ruby-forum.com/t/upgrade-issue/109349 "2007-07-13T18:27:03Z")

</div>

I upgraded from rails 1.1.6 to 1.2.3 and suddenly the db migration stopped working… I had the following in my migration script. create\_table :data\_feeds do |t| # t.column :name, :string t.column :id, :integer t.…

---

## [Including user defined classes](https://www.ruby-forum.com/t/including-user-defined-classes/109351)

<div class="topic-metadata">

**Author:** [@jotape](https://www.ruby-forum.com/u/jotape)\
**Replies:** 0\
**Last updated:** [July 13, 2007, 5:43pm UTC](https://www.ruby-forum.com/t/including-user-defined-classes/109351 "2007-07-13T17:43:26Z")

</div>

Hello again to all! I have made some classes in my projectm and included the in environment.rb to be included. They live in /lib, in my project. I’m doing a reference in one of them to a class in another one, and I …

---

## [Gif creator/editor recommendation](https://www.ruby-forum.com/t/gif-creator-editor-recommendation/109350)

<div class="topic-metadata">

**Author:** [@tdavis1198](https://www.ruby-forum.com/u/tdavis1198)\
**Replies:** 0\
**Last updated:** [July 13, 2007, 5:29pm UTC](https://www.ruby-forum.com/t/gif-creator-editor-recommendation/109350 "2007-07-13T17:29:54Z")

</div>

I need to create some cool buttons for my rails site. Can anyone recommend a good draw program or web based generator for gif’s. I use a Mac

---

## [How do I alter posted data before it is saved in a controlle](https://www.ruby-forum.com/t/how-do-i-alter-posted-data-before-it-is-saved-in-a-controlle/109297)

<div class="topic-metadata">

**Author:** [@summea](https://www.ruby-forum.com/u/summea)\
**Replies:** 6\
**Last updated:** [July 13, 2007, 3:57pm UTC](https://www.ruby-forum.com/t/how-do-i-alter-posted-data-before-it-is-saved-in-a-controlle/109297 "2007-07-13T15:57:38Z")

</div>

Hi everyone, I’m still new to Ruby and Ruby on Rails. I’ve worked with CakePHP for quite a while though, so I’m happy to see that most of what I’ve learned about CakePHP translates over (more or less,) in using Ruby …

---

## [Sending/Receiving Image Data over REST](https://www.ruby-forum.com/t/sending-receiving-image-data-over-rest/92823)

<div class="topic-metadata">

**Author:** [@eblatt](https://www.ruby-forum.com/u/eblatt)\
**Replies:** 4\
**Last updated:** [July 13, 2007, 2:25pm UTC](https://www.ruby-forum.com/t/sending-receiving-image-data-over-rest/92823 "2007-07-13T14:25:20Z")

</div>

Hi, I’ve got a REST API that accepts PUT/POST requests of image data. (Well, that’s the plan.) Here are the relevant lines: My client (using ImageMagick) application reads image data from a file and then coverts it’…

---

## [Test:uncommitted didn't work, so I wrote test:svn\_recent](https://www.ruby-forum.com/t/test-uncommitted-didnt-work-so-i-wrote-test-svn-recent/109232)

<div class="topic-metadata">

**Author:** [@Phlip](https://www.ruby-forum.com/u/Phlip)\
**Replies:** 1\
**Last updated:** [July 13, 2007, 2:15pm UTC](https://www.ruby-forum.com/t/test-uncommitted-didnt-work-so-i-wrote-test-svn-recent/109232 "2007-07-13T14:15:19Z")

</div>

Railsters: Put this into a \*.rake file, and invoke it from a command line as “rake test:svn\_recent”: require ‘fileutils’ task ‘test:svn\_recent’ do svn status. split(“\\n”). map{|f| f =~ /^M\\s+(.\*\_test.rb)/; $1 }. …

---

## [Get model name](https://www.ruby-forum.com/t/get-model-name/109280)

<div class="topic-metadata">

**Author:** [@shafi](https://www.ruby-forum.com/u/shafi)\
**Replies:** 3\
**Last updated:** [July 13, 2007, 2:10pm UTC](https://www.ruby-forum.com/t/get-model-name/109280 "2007-07-13T14:10:43Z")

</div>

hello how to get model name for specific table inside code? i.e. table: people --\> model: person how to get this? thanks

---

## [How can I implement uniqueness?](https://www.ruby-forum.com/t/how-can-i-implement-uniqueness/109317)

<div class="topic-metadata">

**Author:** [@jojojobbins](https://www.ruby-forum.com/u/jojojobbins)\
**Replies:** 3\
**Last updated:** [July 13, 2007, 2:06pm UTC](https://www.ruby-forum.com/t/how-can-i-implement-uniqueness/109317 "2007-07-13T14:06:57Z")

</div>

Hello guys, Suppose I have 2 models: Country and State. The only field they have is called “name”. And I want this field to be unique in Country, and unique in State. But I want the uniqueness of the State’s name to …

---

## [Relationships problems to access](https://www.ruby-forum.com/t/relationships-problems-to-access/109310)

<div class="topic-metadata">

**Author:** [@fcano](https://www.ruby-forum.com/u/fcano)\
**Replies:** 5\
**Last updated:** [July 13, 2007, 2:02pm UTC](https://www.ruby-forum.com/t/relationships-problems-to-access/109310 "2007-07-13T14:02:10Z")

</div>

Hi! I have an events table, a groups table and invitations table. Invitation has event\_id and group\_id. So, Invitation belongs\_to event and belongs\_to group. I have a user table too. User has\_many memberships and a m…

---

## [Has\_many and HABTM in one model](https://www.ruby-forum.com/t/has-many-and-habtm-in-one-model/109172)

<div class="topic-metadata">

**Author:** [@unknown](https://www.ruby-forum.com/u/unknown)\
**Replies:** 5\
**Last updated:** [July 13, 2007, 1:44pm UTC](https://www.ruby-forum.com/t/has-many-and-habtm-in-one-model/109172 "2007-07-13T13:44:04Z")

</div>

Hello, If i have a has\_many and an HABTM relationship what is the best way to manage this? I.E., user id username has\_many :books books id user\_id bookname belongs\_to :user Now what I also want is people to be…

---

## [Find condition calculation](https://www.ruby-forum.com/t/find-condition-calculation/109198)

<div class="topic-metadata">

**Author:** [@nanouk](https://www.ruby-forum.com/u/nanouk)\
**Replies:** 4\
**Last updated:** [July 13, 2007, 1:34pm UTC](https://www.ruby-forum.com/t/find-condition-calculation/109198 "2007-07-13T13:34:13Z")

</div>

I’m trying to do a find with a particular condition. I have a runs table with a n\_passed\_steps column and an n\_failed\_steps column. I’m trying to do a find, to find all records, limited to the last 10, ordered by des…

---

## [Could it be done with web services?](https://www.ruby-forum.com/t/could-it-be-done-with-web-services/109324)

<div class="topic-metadata">

**Author:** [@jsn1](https://www.ruby-forum.com/u/jsn1)\
**Replies:** 0\
**Last updated:** [July 13, 2007, 1:33pm UTC](https://www.ruby-forum.com/t/could-it-be-done-with-web-services/109324 "2007-07-13T13:33:14Z")

</div>

Hi all here is what I need from an Oracle jdeveloper form, click on a button open a web application in RoR, let the user choose several options in the RoR page and calculate a Total Amount, return the total amount to…

---

## [Relative\_url\_root and ENV](https://www.ruby-forum.com/t/relative-url-root-and-env/109325)

<div class="topic-metadata">

**Author:** [@ogeidix](https://www.ruby-forum.com/u/ogeidix)\
**Replies:** 0\
**Last updated:** [July 13, 2007, 1:32pm UTC](https://www.ruby-forum.com/t/relative-url-root-and-env/109325 "2007-07-13T13:32:09Z")

</div>

HI, I have set the enviroment variable RAILS\_RELATIVE\_URL\_ROOT by lighttpd in mod\_fastcgi. It is set because if I debug ENV I can see it but relative\_url\_root doesn’t work because it is about @env Could someone expl…

---

## [Callbacks with parameters](https://www.ruby-forum.com/t/callbacks-with-parameters/109316)

<div class="topic-metadata">

**Author:** [@jotape](https://www.ruby-forum.com/u/jotape)\
**Replies:** 2\
**Last updated:** [July 13, 2007, 12:24pm UTC](https://www.ruby-forum.com/t/callbacks-with-parameters/109316 "2007-07-13T12:24:25Z")

</div>

Hello. I need to pass a user\_id that I have in a session var to a before\_save callback. Is it possible? Thanks

---

## [Rails database backup & restore plugin or rake task](https://www.ruby-forum.com/t/rails-database-backup-restore-plugin-or-rake-task/109235)

<div class="topic-metadata">

**Author:** [@rinda](https://www.ruby-forum.com/u/rinda)\
**Replies:** 1\
**Last updated:** [July 13, 2007, 11:51am UTC](https://www.ruby-forum.com/t/rails-database-backup-restore-plugin-or-rake-task/109235 "2007-07-13T11:51:00Z")

</div>

Hi, Searching in internet finds me mysql specific things and outdated rake tasks. I want a portable one. So using postgresql database, I want to dump my db data into a file. Then I want to load the file into mysql da…

---

## [TypeError on sef-referential association](https://www.ruby-forum.com/t/typeerror-on-sef-referential-association/109222)

<div class="topic-metadata">

**Author:** [@digitalex](https://www.ruby-forum.com/u/digitalex)\
**Replies:** 1\
**Last updated:** [July 13, 2007, 10:58am UTC](https://www.ruby-forum.com/t/typeerror-on-sef-referential-association/109222 "2007-07-13T10:58:45Z")

</div>

I have a self-referential association using the following two models: class User \< ActiveRecord::Base has\_many :incoming\_friendships, :foreign\_key =\> :user1\_id, :class\_name =\> :friendship has\_many :outgoing\_friendshi…

---

## [About actionmailer](https://www.ruby-forum.com/t/about-actionmailer/109304)

<div class="topic-metadata">

**Author:** [@vishal](https://www.ruby-forum.com/u/vishal)\
**Replies:** 0\
**Last updated:** [July 13, 2007, 9:56am UTC](https://www.ruby-forum.com/t/about-actionmailer/109304 "2007-07-13T09:56:28Z")

</div>

In smts\_settings for configuration of mailer I want the address, domain and port for the yahoo mail server. I used it as given below is it right. If no please suggest the correct one. :address =\> “mail.yahoo.co.in”, …

---

## [(no subject)](https://www.ruby-forum.com/t/no-subject/109305)

<div class="topic-metadata">

**Author:** [@chris\_loper](https://www.ruby-forum.com/u/chris_loper)\
**Replies:** 0\
**Last updated:** [July 13, 2007, 9:52am UTC](https://www.ruby-forum.com/t/no-subject/109305 "2007-07-13T09:52:28Z")

</div>

So I have run into a problem: I have a restful setup where a user clicks on an item to view it. once viewing the item, they can drag&drop characteristics onto the item. map.resources :items, :member =\> { :apply =\> :po…

---

## [Globalize Currency | UPDATE | CREATE](https://www.ruby-forum.com/t/globalize-currency-update-create/109301)

<div class="topic-metadata">

**Author:** [@Dusan](https://www.ruby-forum.com/u/Dusan)\
**Replies:** 0\
**Last updated:** [July 13, 2007, 9:20am UTC](https://www.ruby-forum.com/t/globalize-currency-update-create/109301 "2007-07-13T09:20:21Z")

</div>

Hi, I am just trying to use globalize plugin, mainly for currency formatting. Everything works fine (it’s really easy to use globalize, I love it :slight\_smile: except creating and/or updating record fields that are …

---

## [Multiple layers nested has\_many through](https://www.ruby-forum.com/t/multiple-layers-nested-has-many-through/106261)

<div class="topic-metadata">

**Author:** [@ericgoodwin](https://www.ruby-forum.com/u/ericgoodwin)\
**Replies:** 1\
**Last updated:** [July 13, 2007, 8:31am UTC](https://www.ruby-forum.com/t/multiple-layers-nested-has-many-through/106261 "2007-07-13T08:31:15Z")

</div>

I’ve seen previous posts finding ways to do multiple has\_many :through assocations like the following class A \< ActiveRecord::Base has\_many :xs has\_many :ys, :through=\>:xs has\_many :zs, :through=\>:ys end I’ve seen…

---

## [Will ThickBox work with Ruby on rails?](https://www.ruby-forum.com/t/will-thickbox-work-with-ruby-on-rails/109298)

<div class="topic-metadata">

**Author:** [@unnikrishnanes](https://www.ruby-forum.com/u/unnikrishnanes)\
**Replies:** 0\
**Last updated:** [July 13, 2007, 8:30am UTC](https://www.ruby-forum.com/t/will-thickbox-work-with-ruby-on-rails/109298 "2007-07-13T08:30:24Z")

</div>

anybody know whether Thick box can be used with Ruby on rails?

---

## [Instance variable has different value in layout vs. view!](https://www.ruby-forum.com/t/instance-variable-has-different-value-in-layout-vs-view/109295)

<div class="topic-metadata">

**Author:** [@mindel](https://www.ruby-forum.com/u/mindel)\
**Replies:** 1\
**Last updated:** [July 13, 2007, 5:54am UTC](https://www.ruby-forum.com/t/instance-variable-has-different-value-in-layout-vs-view/109295 "2007-07-13T05:54:23Z")

</div>

Hi folks, My controller sets an instance variable (@item) which somehow contains a different value in the layout than it does in the view. The controller (items\_controller), has this action: def show @item = Item.fi…

---

## [Trouble figuring out select tags](https://www.ruby-forum.com/t/trouble-figuring-out-select-tags/109282)

<div class="topic-metadata">

**Author:** [@smc7000](https://www.ruby-forum.com/u/smc7000)\
**Replies:** 5\
**Last updated:** [July 13, 2007, 5:33am UTC](https://www.ruby-forum.com/t/trouble-figuring-out-select-tags/109282 "2007-07-13T05:33:03Z")

</div>

Sorry guys - such an obtuse question, but with all the myriad possibilities out there for using select statements in my rails template, I can’t figure out which one is the best. Here’s my problem: I have a very simple…

---

## [Acts as list -- adding or moving new item to new location](https://www.ruby-forum.com/t/acts-as-list-adding-or-moving-new-item-to-new-location/109248)

<div class="topic-metadata">

**Author:** [@mike](https://www.ruby-forum.com/u/mike)\
**Replies:** 1\
**Last updated:** [July 13, 2007, 4:07am UTC](https://www.ruby-forum.com/t/acts-as-list-adding-or-moving-new-item-to-new-location/109248 "2007-07-13T04:07:56Z")

</div>

right now i’m adding an item to my ‘list’ but i’m unsure how to move it to a certain spot in the list. specifically i want to put it at the bottom of the list. i assumed that if i did something like parent.children \<\< …

---

## [Cookie based flash](https://www.ruby-forum.com/t/cookie-based-flash/109261)

<div class="topic-metadata">

**Author:** [@joe-dumoulin](https://www.ruby-forum.com/u/joe-dumoulin)\
**Replies:** 2\
**Last updated:** [July 13, 2007, 4:02am UTC](https://www.ruby-forum.com/t/cookie-based-flash/109261 "2007-07-13T04:02:55Z")

</div>

I’ve got a Rails app in which I do not need to use sessions, with one exception: I want to use RoR flash. Now, I much prefer to use true stateless client-server, thus avoiding the hassle of dealing with server-side se…

---

## [How to debug failure on start from InstantRails](https://www.ruby-forum.com/t/how-to-debug-failure-on-start-from-instantrails/109164)

<div class="topic-metadata">

**Author:** [@lunaclaire](https://www.ruby-forum.com/u/lunaclaire)\
**Replies:** 3\
**Last updated:** [July 13, 2007, 1:59am UTC](https://www.ruby-forum.com/t/how-to-debug-failure-on-start-from-instantrails/109164 "2007-07-13T01:59:45Z")

</div>

I made some change that I cant track down by looking at source code that prevents my app from starting when launching from InstantRails. The console window that InstantRails opens displays some info, but it closes the…

---

## [Why does this RMacik Attachement\_foo code not work?](https://www.ruby-forum.com/t/why-does-this-rmacik-attachement-foo-code-not-work/109277)

<div class="topic-metadata">

**Author:** [@emuen](https://www.ruby-forum.com/u/emuen)\
**Replies:** 0\
**Last updated:** [July 13, 2007, 12:22am UTC](https://www.ruby-forum.com/t/why-does-this-rmacik-attachement-foo-code-not-work/109277 "2007-07-13T00:22:29Z")

</div>

Hi why des this not work? It should work, but the thumbnails does not get saved. has\_attachment :storage =\> :file\_system, :max\_size =\> 500.megabytes, :resize\_to =\> "300\>", …

---

## [OS X Server & Ruby on Rails](https://www.ruby-forum.com/t/os-x-server-ruby-on-rails/109266)

<div class="topic-metadata">

**Author:** [@sshefer](https://www.ruby-forum.com/u/sshefer)\
**Replies:** 1\
**Last updated:** [July 13, 2007, 12:14am UTC](https://www.ruby-forum.com/t/os-x-server-ruby-on-rails/109266 "2007-07-13T00:14:32Z")

</div>

Not really a question so much as just wondering… Does anyone have any good links to setting up Ruby on Rails on OS X Server to act as a private testing server? I have an old PowerBook lying around and with 10.5 comin…

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

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