# Rails

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

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

---

## [Saving a record](https://www.ruby-forum.com/t/saving-a-record/103175)

<div class="topic-metadata">

**Author:** [@List\_Catcher](https://www.ruby-forum.com/u/List_Catcher)\
**Replies:** 7\
**Last updated:** [May 3, 2007, 4:46am UTC](https://www.ruby-forum.com/t/saving-a-record/103175 "2007-05-03T04:46:44Z")

</div>

As I plod on in my journey to grasp Rails (and Ruby) I’m often surprised by the difficulty in figuring out how to do something. Most of the time the surprise is a pleasant one, in that it’s much easier than I expected…

---

## [Mongrel vs Apache with Mongrel](https://www.ruby-forum.com/t/mongrel-vs-apache-with-mongrel/103210)

<div class="topic-metadata">

**Author:** [@giorgio](https://www.ruby-forum.com/u/giorgio)\
**Replies:** 2\
**Last updated:** [May 3, 2007, 4:23am UTC](https://www.ruby-forum.com/t/mongrel-vs-apache-with-mongrel/103210 "2007-05-03T04:23:43Z")

</div>

Hi, Is there any point in running Apache in front of Mongrel if you are not running a Mongrel Cluster? I have a small app with only a few users and currently just using standalone Mongrel. I cant really see any advan…

---

## [Marking/Flagging a record as deleted/expired instead of actu](https://www.ruby-forum.com/t/marking-flagging-a-record-as-deleted-expired-instead-of-actu/103224)

<div class="topic-metadata">

**Author:** [@james](https://www.ruby-forum.com/u/james)\
**Replies:** 3\
**Last updated:** [May 3, 2007, 4:02am UTC](https://www.ruby-forum.com/t/marking-flagging-a-record-as-deleted-expired-instead-of-actu/103224 "2007-05-03T04:02:42Z")

</div>

Hi, I’ve a system which does not delete records from the database but marks them as ‘expired’ and the excludes such in any view of the current data. Is there an easy way to override the behaviour of AR.destroy to hav…

---

## [\[ANN\] Plugins for Test Helpers and Abstract Test Cases](https://www.ruby-forum.com/t/ann-plugins-for-test-helpers-and-abstract-test-cases/103225)

<div class="topic-metadata">

**Author:** [@John\_WSLong](https://www.ruby-forum.com/u/John_WSLong)\
**Replies:** 0\
**Last updated:** [May 3, 2007, 4:01am UTC](https://www.ruby-forum.com/t/ann-plugins-for-test-helpers-and-abstract-test-cases/103225 "2007-05-03T04:01:42Z")

</div>

I just released two Rails plugins that should make testing a little easier for some of you. The test\_helpers plugin makes it easy to DRY up your test cases by moving shared code into modules. It includes the handy d…

---

## [Newbie question: How to get an object in the Controller from](https://www.ruby-forum.com/t/newbie-question-how-to-get-an-object-in-the-controller-from/103221)

<div class="topic-metadata">

**Author:** [@anupam](https://www.ruby-forum.com/u/anupam)\
**Replies:** 1\
**Last updated:** [May 3, 2007, 3:22am UTC](https://www.ruby-forum.com/t/newbie-question-how-to-get-an-object-in-the-controller-from/103221 "2007-05-03T03:22:39Z")

</div>

Hi, I’m trying to pass an object from the View to the controller as a hidden field. And am confused about a few things. For a hidden field, how do I pass a complete object to the controller? For example, I have an o…

---

## [No route found to match "/application/signin"](https://www.ruby-forum.com/t/no-route-found-to-match-application-signin/103222)

<div class="topic-metadata">

**Author:** [@Ryan\_Cush](https://www.ruby-forum.com/u/Ryan_Cush)\
**Replies:** 0\
**Last updated:** [May 3, 2007, 3:21am UTC](https://www.ruby-forum.com/t/no-route-found-to-match-application-signin/103222 "2007-05-03T03:21:42Z")

</div>

I’m posting this because I ran into a problem and had difficulty tracking down the answer. In fact, the answer was in another ruby-forum post, but the Search feature didn’t locate it via the keywords I was using. Ho…

---

## [Inventory managment](https://www.ruby-forum.com/t/inventory-managment/103218)

<div class="topic-metadata">

**Author:** [@longinos](https://www.ruby-forum.com/u/longinos)\
**Replies:** 0\
**Last updated:** [May 3, 2007, 2:18am UTC](https://www.ruby-forum.com/t/inventory-managment/103218 "2007-05-03T02:18:50Z")

</div>

the question is, if you can have your inventory manegement in the same web, for exemple, when entering a new product, you could asign a number that you have to sell, and that you can add more, another exampli, if I ha…

---

## [\[ANN\] Smart Session Store plugin](https://www.ruby-forum.com/t/ann-smart-session-store-plugin/103091)

<div class="topic-metadata">

**Author:** [@fcheung](https://www.ruby-forum.com/u/fcheung)\
**Replies:** 8\
**Last updated:** [May 3, 2007, 12:58am UTC](https://www.ruby-forum.com/t/ann-smart-session-store-plugin/103091 "2007-05-03T00:58:27Z")

</div>

We’ve been having a few niggles with session management, and I’ve just released a plugin that deals with them. In a nutshell there are problems when you have multiple concurrent requests (several ajax calls, multiple …

---

## [Lost MySQL connections accessing session store](https://www.ruby-forum.com/t/lost-mysql-connections-accessing-session-store/92861)

<div class="topic-metadata">

**Author:** [@DZDZDZ](https://www.ruby-forum.com/u/DZDZDZ)\
**Replies:** 4\
**Last updated:** [May 3, 2007, 12:55am UTC](https://www.ruby-forum.com/t/lost-mysql-connections-accessing-session-store/92861 "2007-05-03T00:55:32Z")

</div>

Since putting our application into production, I’ve been seeing random lost connections to our MySQL server, always when the application is accessing the session store, and at no other time. Apparently randomly, I get…

---

## [Test Associations are Preloaded](https://www.ruby-forum.com/t/test-associations-are-preloaded/103214)

<div class="topic-metadata">

**Author:** [@nappin](https://www.ruby-forum.com/u/nappin)\
**Replies:** 0\
**Last updated:** [May 3, 2007, 12:28am UTC](https://www.ruby-forum.com/t/test-associations-are-preloaded/103214 "2007-05-03T00:28:48Z")

</div>

What’s the best way to test that all assocaitions are preloaded when a method is called? For example, do\_something is a method that makes a db call and preloads several associations. Is there a way to write a test th…

---

## [ActiveResource: Howto use custom header fields](https://www.ruby-forum.com/t/activeresource-howto-use-custom-header-fields/103119)

<div class="topic-metadata">

**Author:** [@cmanruby](https://www.ruby-forum.com/u/cmanruby)\
**Replies:** 3\
**Last updated:** [May 3, 2007, 12:25am UTC](https://www.ruby-forum.com/t/activeresource-howto-use-custom-header-fields/103119 "2007-05-03T00:25:31Z")

</div>

Hi, I’m using the ActiveResource (beta) gem. I need to change the header fields for the request. There is “default\_header” in ActiveResource::Connection which is “Content-type: application/xml”. I do not see how to c…

---

## [Restful\_authentication and edge rails problems?](https://www.ruby-forum.com/t/restful-authentication-and-edge-rails-problems/103200)

<div class="topic-metadata">

**Author:** [@adam](https://www.ruby-forum.com/u/adam)\
**Replies:** 2\
**Last updated:** [May 3, 2007, 12:20am UTC](https://www.ruby-forum.com/t/restful-authentication-and-edge-rails-problems/103200 "2007-05-03T00:20:05Z")

</div>

Hi, Has anyone any idea how to solve this: I have the following in my routes.rb RESTful authentication map.resources :users, :sessions map.signup '/signup', :controller =\> 'users', :action =\> 'new' map.login '/login…

---

## [Ruby/ajax strange problem](https://www.ruby-forum.com/t/ruby-ajax-strange-problem/93275)

<div class="topic-metadata">

**Author:** [@adi](https://www.ruby-forum.com/u/adi)\
**Replies:** 1\
**Last updated:** [May 2, 2007, 10:32pm UTC](https://www.ruby-forum.com/t/ruby-ajax-strange-problem/93275 "2007-05-02T22:32:18Z")

</div>

I have a ajax request that loads me a ruby page in my mainArea div: new Ajax.Request(window, {asynchronous:true, evalScripts:true, onSuccess:function(req){$(‘mainArea’).innerHTML=req.responseText}}); where ‘window’ is…

---

## [How to disable past days with jscalendar?](https://www.ruby-forum.com/t/how-to-disable-past-days-with-jscalendar/103203)

<div class="topic-metadata">

**Author:** [@fernando](https://www.ruby-forum.com/u/fernando)\
**Replies:** 0\
**Last updated:** [May 2, 2007, 10:14pm UTC](https://www.ruby-forum.com/t/how-to-disable-past-days-with-jscalendar/103203 "2007-05-02T22:14:56Z")

</div>

I want to display a calendar, but I don’t want let the user to select days from the past. I tried with disableFunc, but i couldn’t make it work. Any help? Thank you a lot.

---

## [Can table ID column be a string?](https://www.ruby-forum.com/t/can-table-id-column-be-a-string/103191)

<div class="topic-metadata">

**Author:** [@Dcjgoose](https://www.ruby-forum.com/u/Dcjgoose)\
**Replies:** 1\
**Last updated:** [May 2, 2007, 10:06pm UTC](https://www.ruby-forum.com/t/can-table-id-column-be-a-string/103191 "2007-05-02T22:06:13Z")

</div>

Hello, Does rails assume that all table columns called “id” are int’s? Asking because I am connecting to a non-rails db and some of the tables have an id column that is defined as string. Thanks!

---

## [Copy a record and its has\_many associated objects](https://www.ruby-forum.com/t/copy-a-record-and-its-has-many-associated-objects/103202)

<div class="topic-metadata">

**Author:** [@casper\_the\_ghost](https://www.ruby-forum.com/u/casper_the_ghost)\
**Replies:** 0\
**Last updated:** [May 2, 2007, 10:01pm UTC](https://www.ruby-forum.com/t/copy-a-record-and-its-has-many-associated-objects/103202 "2007-05-02T22:01:12Z")

</div>

Is there a simple, built-in way to create a copy of a record with copies of all the original record’s associated has\_many objects?

---

## [Interesting idea](https://www.ruby-forum.com/t/interesting-idea/103192)

<div class="topic-metadata">

**Author:** [@zeka](https://www.ruby-forum.com/u/zeka)\
**Replies:** 2\
**Last updated:** [May 2, 2007, 9:59pm UTC](https://www.ruby-forum.com/t/interesting-idea/103192 "2007-05-02T21:59:12Z")

</div>

Hey guys, There is something I have been trying to implement but so far no luck. Basically, I want to have helpers that generate HTML around given content, similar to ActionView’s form\_for. Besides, I want to keep th…

---

## [What shoud flash\[:alert\] be in edge rails?](https://www.ruby-forum.com/t/what-shoud-flash-alert-be-in-edge-rails/103193)

<div class="topic-metadata">

**Author:** [@josh](https://www.ruby-forum.com/u/josh)\
**Replies:** 2\
**Last updated:** [May 2, 2007, 9:52pm UTC](https://www.ruby-forum.com/t/what-shoud-flash-alert-be-in-edge-rails/103193 "2007-05-02T21:52:54Z")

</div>

Hi I haveJust attmpting to start using edge rails for the first time. Couldnt find the answer to this anywhere, below is a small peiece of code I have been using, but flash\[:notice\] does not seem to work anymore What…

---

## [Determining checked checkboxes](https://www.ruby-forum.com/t/determining-checked-checkboxes/103106)

<div class="topic-metadata">

**Author:** [@georgeuoa](https://www.ruby-forum.com/u/georgeuoa)\
**Replies:** 2\
**Last updated:** [May 2, 2007, 9:35pm UTC](https://www.ruby-forum.com/t/determining-checked-checkboxes/103106 "2007-05-02T21:35:27Z")

</div>

Hi guys Am a newbie in rails please forgive my ignorance. i have set of search results i have appended a checkbox to each of the results and would like to give the user some freedom to choose what he/she likes and ma…

---

## [Flash message == if statement over-riding?](https://www.ruby-forum.com/t/flash-message-if-statement-over-riding/103195)

<div class="topic-metadata">

**Author:** [@ByENNEN](https://www.ruby-forum.com/u/ByENNEN)\
**Replies:** 1\
**Last updated:** [May 2, 2007, 9:07pm UTC](https://www.ruby-forum.com/t/flash-message-if-statement-over-riding/103195 "2007-05-02T21:07:08Z")

</div>

Here is the code I need help with: http://pastie.caboo.se/58307 My problem is I have a custom save message throughout my app. My client needs the message to be different for one save in the app. If you click on the …

---

## [ActionMailer with no auth](https://www.ruby-forum.com/t/actionmailer-with-no-auth/93047)

<div class="topic-metadata">

**Author:** [@acras](https://www.ruby-forum.com/u/acras)\
**Replies:** 4\
**Last updated:** [May 2, 2007, 8:10pm UTC](https://www.ruby-forum.com/t/actionmailer-with-no-auth/93047 "2007-05-02T20:10:00Z")

</div>

Hello, How can I send mail via ActionMailer connecting to the SMTP server with no Authentication? I’ve tried to ommit the the authentication key on the configuration hash, I’ve tried to set it to nil and all I get is…

---

## [Railspdf plugin problem](https://www.ruby-forum.com/t/railspdf-plugin-problem/51421)

<div class="topic-metadata">

**Author:** [@Heru\_Y](https://www.ruby-forum.com/u/Heru_Y)\
**Replies:** 9\
**Last updated:** [May 2, 2007, 8:06pm UTC](https://www.ruby-forum.com/t/railspdf-plugin-problem/51421 "2007-05-02T20:06:11Z")

</div>

Hi, For my app i need to generate pdf file for reports. I am trying the railspdf plugin, got it installed using command: ruby script/plugin install svn://rubyforge.org//var/svn/railspdfplugin/railspdf/ The problem …

---

## [RJS - changing the status of radio button](https://www.ruby-forum.com/t/rjs-changing-the-status-of-radio-button/103180)

<div class="topic-metadata">

**Author:** [@kadoudal](https://www.ruby-forum.com/u/kadoudal)\
**Replies:** 1\
**Last updated:** [May 2, 2007, 7:53pm UTC](https://www.ruby-forum.com/t/rjs-changing-the-status-of-radio-button/103180 "2007-05-02T19:53:58Z")

</div>

I am trying to change the checked button in a radio button array named ‘prop\_type’ using page \<\< “$(‘prop\_type\[0\]’) = ‘checked’” got an error on the left side : prop\_type\[0\]… it seems correct … or not ? kad

---

## [Multiple Nested Includes](https://www.ruby-forum.com/t/multiple-nested-includes/91524)

<div class="topic-metadata">

**Author:** [@nappin](https://www.ruby-forum.com/u/nappin)\
**Replies:** 1\
**Last updated:** [May 2, 2007, 7:48pm UTC](https://www.ruby-forum.com/t/multiple-nested-includes/91524 "2007-05-02T19:48:43Z")

</div>

I’m trying to do multiple nested includes on an AR find. Something like: @result = User.find\_by\_id(id, :include =\> \[:something, \[:nest\_1 =\> \[:a, :b\]\], \[:nest\_2 =\> \[:c, :d\]\]\]) Unfortunately when I view my logs, it se…

---

## [Chaining together Rakefiles](https://www.ruby-forum.com/t/chaining-together-rakefiles/103133)

<div class="topic-metadata">

**Author:** [@jjantz](https://www.ruby-forum.com/u/jjantz)\
**Replies:** 2\
**Last updated:** [May 2, 2007, 7:43pm UTC](https://www.ruby-forum.com/t/chaining-together-rakefiles/103133 "2007-05-02T19:43:57Z")

</div>

Hello. Can someone explain the best way to chain together Rakefiles? I am working on a project with the following layout: comon libraries depot/common one rails appserver depot/projectA another rails appserver depot…

---

## [Clone ActiveRecords](https://www.ruby-forum.com/t/clone-activerecords/103179)

<div class="topic-metadata">

**Author:** [@edmoss](https://www.ruby-forum.com/u/edmoss)\
**Replies:** 1\
**Last updated:** [May 2, 2007, 7:33pm UTC](https://www.ruby-forum.com/t/clone-activerecords/103179 "2007-05-02T19:33:56Z")

</div>

I am using the Marshal module to create a deep clone of an ActiveRecord object hierarchy… i.e. an object that has\_many children, which at their turn have many children: In my model file I have: def deep\_clone() aClo…

---

## [Deploying another application as subdomain](https://www.ruby-forum.com/t/deploying-another-application-as-subdomain/103184)

<div class="topic-metadata">

**Author:** [@dorelal](https://www.ruby-forum.com/u/dorelal)\
**Replies:** 0\
**Last updated:** [May 2, 2007, 7:26pm UTC](https://www.ruby-forum.com/t/deploying-another-application-as-subdomain/103184 "2007-05-02T19:26:54Z")

</div>

Let’s say that I have an application up and running at http://eii.com I and developing another application that is complimentary to eii.com and have decided to serve that application using http://services.eii.com Now…

---

## [Submit a form\_remote from RJS](https://www.ruby-forum.com/t/submit-a-form-remote-from-rjs/103182)

<div class="topic-metadata">

**Author:** [@kadoudal](https://www.ruby-forum.com/u/kadoudal)\
**Replies:** 0\
**Last updated:** [May 2, 2007, 7:14pm UTC](https://www.ruby-forum.com/t/submit-a-form-remote-from-rjs/103182 "2007-05-02T19:14:00Z")

</div>

I have a remote\_form : \<% form\_remote\_tag( :url =\>{:action =\> ‘list’}, :html =\> {:id =\> ‘prop\_search\_form’, :name =\> “prop\_search\_form”} ) do %\> … \<%= submit\_tag “Search”, {:id =\> “search\_btn”, :class =\> ‘inputSubmi…

---

## [How to refactor this](https://www.ruby-forum.com/t/how-to-refactor-this/103178)

<div class="topic-metadata">

**Author:** [@unknown](https://www.ruby-forum.com/u/unknown)\
**Replies:** 0\
**Last updated:** [May 2, 2007, 6:56pm UTC](https://www.ruby-forum.com/t/how-to-refactor-this/103178 "2007-05-02T18:56:51Z")

</div>

Hi, I’ve written some model specs, and some code to make them all pass, but I don’t like the code I’ve written… it’s in desperate need of refactoring. I’ve included the code, as well as the specs to help you underst…

---

## [Upload\_column - problem cropping image](https://www.ruby-forum.com/t/upload-column-problem-cropping-image/103177)

<div class="topic-metadata">

**Author:** [@josh](https://www.ruby-forum.com/u/josh)\
**Replies:** 0\
**Last updated:** [May 2, 2007, 6:56pm UTC](https://www.ruby-forum.com/t/upload-column-problem-cropping-image/103177 "2007-05-02T18:56:45Z")

</div>

I am having a few problems using the upload\_column plugin. When I have this in my model image\_column :image, :versions =\> { :thumb =\> “c40x40”, :large =\> “200x300” } I get the following error undefined method \`crop\_…

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

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