# Rails

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

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

---

## [Invoking a method by name](https://www.ruby-forum.com/t/invoking-a-method-by-name/90202)

<div class="topic-metadata">

**Author:** [@rlwinter](https://www.ruby-forum.com/u/rlwinter)\
**Replies:** 2\
**Last updated:** [March 26, 2007, 8:41pm UTC](https://www.ruby-forum.com/t/invoking-a-method-by-name/90202 "2007-03-26T20:41:21Z")

</div>

Hello all, I have a need to invoke methods dynamically by name. Say I have a method like: def invoke\_method\_with\_name(method\_name) person = Person.find(params\[:id\]) method\_to\_invoke = ~~ some code to find the method…

---

## [Best platform for production deployment of RoR applications](https://www.ruby-forum.com/t/best-platform-for-production-deployment-of-ror-applications/90113)

<div class="topic-metadata">

**Author:** [@David\_JSOrman](https://www.ruby-forum.com/u/David_JSOrman)\
**Replies:** 3\
**Last updated:** [March 26, 2007, 8:33pm UTC](https://www.ruby-forum.com/t/best-platform-for-production-deployment-of-ror-applications/90113 "2007-03-26T20:33:21Z")

</div>

Hi, I’m going to be setting up a small server farm for my production RoR application deployments. I’m now at the point I need to pick what software I’ll be running/management techniques. So, my question is, what OS (…

---

## [Local network](https://www.ruby-forum.com/t/local-network/90199)

<div class="topic-metadata">

**Author:** [@longinos](https://www.ruby-forum.com/u/longinos)\
**Replies:** 1\
**Last updated:** [March 26, 2007, 8:31pm UTC](https://www.ruby-forum.com/t/local-network/90199 "2007-03-26T20:31:20Z")

</div>

Can ruby on rails be shared in a local network, with no internet conection? let’s say a hardware store, for intentory, administration etc. is that posible? or is ror only for intenet ? I’m asking this, because, I’m i…

---

## [How do you initialize subclasses of ActiveRecord?](https://www.ruby-forum.com/t/how-do-you-initialize-subclasses-of-activerecord/90185)

<div class="topic-metadata">

**Author:** [@Yajiv](https://www.ruby-forum.com/u/Yajiv)\
**Replies:** 1\
**Last updated:** [March 26, 2007, 8:31pm UTC](https://www.ruby-forum.com/t/how-do-you-initialize-subclasses-of-activerecord/90185 "2007-03-26T20:31:20Z")

</div>

Having a class class Recipe \< ActiveRecord def initialize super() @someingredients =\[“salt”\] end end It appears that Recipe.find(:all) returns recipes who haven’t been ‘initialized’ How do you setup a suitable …

---

## [Rails developers in Johannesburg](https://www.ruby-forum.com/t/rails-developers-in-johannesburg/90200)

<div class="topic-metadata">

**Author:** [@john-anes](https://www.ruby-forum.com/u/john-anes)\
**Replies:** 0\
**Last updated:** [March 26, 2007, 8:24pm UTC](https://www.ruby-forum.com/t/rails-developers-in-johannesburg/90200 "2007-03-26T20:24:18Z")

</div>

Hi y’all I’m the lead developer for a rails project based in Johannesburg, South Africa. We’re looking for rails developers, preferably based in South Africa. Mail removed\_email\_address@domain.invalid if you’re intere…

---

## [App vs Engine - raise error message](https://www.ruby-forum.com/t/app-vs-engine-raise-error-message/90203)

<div class="topic-metadata">

**Author:** [@Wes\_Hays](https://www.ruby-forum.com/u/Wes_Hays)\
**Replies:** 0\
**Last updated:** [March 26, 2007, 8:17pm UTC](https://www.ruby-forum.com/t/app-vs-engine-raise-error-message/90203 "2007-03-26T20:17:18Z")

</div>

I have some code that I was duplicating across applications so I made it an engine. The engine works fine but the only problem is when I raise an error in the before\_destroy method in my model (the model is not in the …

---

## [File not found](https://www.ruby-forum.com/t/file-not-found/90194)

<div class="topic-metadata">

**Author:** [@2dc](https://www.ruby-forum.com/u/2dc)\
**Replies:** 1\
**Last updated:** [March 26, 2007, 8:11pm UTC](https://www.ruby-forum.com/t/file-not-found/90194 "2007-03-26T20:11:38Z")

</div>

Hi, I’ve just installed ruby on rails on my fedora core 6 machine. I initialized the project, genarated a simple controller and the associated view but when i try to access my page (http://localhost:3000/my\_controlle…

---

## [Can't use models in migrations](https://www.ruby-forum.com/t/cant-use-models-in-migrations/90085)

<div class="topic-metadata">

**Author:** [@henster](https://www.ruby-forum.com/u/henster)\
**Replies:** 1\
**Last updated:** [March 26, 2007, 8:05pm UTC](https://www.ruby-forum.com/t/cant-use-models-in-migrations/90085 "2007-03-26T20:05:13Z")

</div>

Hi there, This always used to work for me… but not now. I want to blame Rails 1.2 but I’m sure its not. I can’t use AR models in my migrations. To make sure its not just my dodgy code I tried to do the same with a we…

---

## [Problems with destroy action](https://www.ruby-forum.com/t/problems-with-destroy-action/90192)

<div class="topic-metadata">

**Author:** [@PaSSS\_lo\_Geyer](https://www.ruby-forum.com/u/PaSSS_lo_Geyer)\
**Replies:** 2\
**Last updated:** [March 26, 2007, 7:51pm UTC](https://www.ruby-forum.com/t/problems-with-destroy-action/90192 "2007-03-26T19:51:11Z")

</div>

i was trying to destroy an item from my database using charges/destroy action, and i get this message: Processing ChargesController#destroy (for 127.0.0.1 at 2007-03-26 14:20:00) \[GET\] Session ID: f7b10d423fe59d16286…

---

## [Moving Application from Windows WEBrick to Linux Apache host](https://www.ruby-forum.com/t/moving-application-from-windows-webrick-to-linux-apache-host/90193)

<div class="topic-metadata">

**Author:** [@david](https://www.ruby-forum.com/u/david)\
**Replies:** 0\
**Last updated:** [March 26, 2007, 7:33pm UTC](https://www.ruby-forum.com/t/moving-application-from-windows-webrick-to-linux-apache-host/90193 "2007-03-26T19:33:16Z")

</div>

Hello, I have some kind of problem. I was trying to upload sample application to my hosting which supports RoR 1.2 and I have a lot of problems. I just can’t start the application. I don’t have SSH access to it. Ther…

---

## [Fiel permissions - how much can I lock down my app's files?](https://www.ruby-forum.com/t/fiel-permissions-how-much-can-i-lock-down-my-apps-files/90189)

<div class="topic-metadata">

**Author:** [@wpwood](https://www.ruby-forum.com/u/wpwood)\
**Replies:** 0\
**Last updated:** [March 26, 2007, 7:21pm UTC](https://www.ruby-forum.com/t/fiel-permissions-how-much-can-i-lock-down-my-apps-files/90189 "2007-03-26T19:21:56Z")

</div>

Sorry for the cross-post. Having give it some additional thought, I realize now I should have posted this here first ;-p I want to lock down my site as much as possible and would like to set the file permissions as r…

---

## [Soap4r for one controller](https://www.ruby-forum.com/t/soap4r-for-one-controller/90190)

<div class="topic-metadata">

**Author:** [@jsmecham](https://www.ruby-forum.com/u/jsmecham)\
**Replies:** 0\
**Last updated:** [March 26, 2007, 7:10pm UTC](https://www.ruby-forum.com/t/soap4r-for-one-controller/90190 "2007-03-26T19:10:57Z")

</div>

Is there a way to use soap4r for only one controller and use the built-in ruby standard library for others?

---

## [mySql or Postgresql, that is the question?](https://www.ruby-forum.com/t/mysql-or-postgresql-that-is-the-question/89937)

<div class="topic-metadata">

**Author:** [@dima](https://www.ruby-forum.com/u/dima)\
**Replies:** 6\
**Last updated:** [March 26, 2007, 7:07pm UTC](https://www.ruby-forum.com/t/mysql-or-postgresql-that-is-the-question/89937 "2007-03-26T19:07:52Z")

</div>

I have to decide witch database to use in a Rails project for the client. It has to do with some payment system and should be fast. I have more knowledge about mySql but Postgresql looks like a better choice because …

---

## [Fixing routes when Rails app is subdirectory](https://www.ruby-forum.com/t/fixing-routes-when-rails-app-is-subdirectory/90188)

<div class="topic-metadata">

**Author:** [@zakifataya](https://www.ruby-forum.com/u/zakifataya)\
**Replies:** 0\
**Last updated:** [March 26, 2007, 7:05pm UTC](https://www.ruby-forum.com/t/fixing-routes-when-rails-app-is-subdirectory/90188 "2007-03-26T19:05:44Z")

</div>

If I have Apache configured to proxy /foo to Rails behind Mongrel, how do I fix routes to always include the subdirectory? In other words, main Rails page is here: http://127.0.0.1/foo/ But application environment pa…

---

## [File Listing](https://www.ruby-forum.com/t/file-listing/90171)

<div class="topic-metadata">

**Author:** [@seanmctex](https://www.ruby-forum.com/u/seanmctex)\
**Replies:** 1\
**Last updated:** [March 26, 2007, 7:00pm UTC](https://www.ruby-forum.com/t/file-listing/90171 "2007-03-26T19:00:12Z")

</div>

Completely new to Rails. Actually, I’m not even the direct programmer of the site. Our web administrator is bringing in rails to replace what we have now and to speed deployment of new information. By an large, our …

---

## [How put the project online?](https://www.ruby-forum.com/t/how-put-the-project-online/90152)

<div class="topic-metadata">

**Author:** [@Needhelp](https://www.ruby-forum.com/u/Needhelp)\
**Replies:** 2\
**Last updated:** [March 26, 2007, 6:45pm UTC](https://www.ruby-forum.com/t/how-put-the-project-online/90152 "2007-03-26T18:45:38Z")

</div>

I working in my first project and i need now to upload the files. Question : on my project has many files without use (like the testÂ´s and others) how can i send only the “production” files

---

## [Date Functions](https://www.ruby-forum.com/t/date-functions/90182)

<div class="topic-metadata">

**Author:** [@mick](https://www.ruby-forum.com/u/mick)\
**Replies:** 1\
**Last updated:** [March 26, 2007, 6:31pm UTC](https://www.ruby-forum.com/t/date-functions/90182 "2007-03-26T18:31:47Z")

</div>

Hi, I would like to be able to do a date comparison to return the number of days left until a date (stored in my database) is reached. I can’t seem to find a ruby function that will do such an operation and regardless…

---

## [Component-Based software development](https://www.ruby-forum.com/t/component-based-software-development/90184)

<div class="topic-metadata">

**Author:** [@Thiago\_Bueno\_Silva](https://www.ruby-forum.com/u/Thiago_Bueno_Silva)\
**Replies:** 0\
**Last updated:** [March 26, 2007, 6:25pm UTC](https://www.ruby-forum.com/t/component-based-software-development/90184 "2007-03-26T18:25:40Z")

</div>

Hy Guys, I’m reading a book called “UML Components - A Simple Process for Specifying Component Based Software” (by John Cheesman and Jonh Daniels) and i was wandering if this kind of development is possible on Ruby an…

---

## [Ruby question](https://www.ruby-forum.com/t/ruby-question/90181)

<div class="topic-metadata">

**Author:** [@jim](https://www.ruby-forum.com/u/jim)\
**Replies:** 1\
**Last updated:** [March 26, 2007, 6:20pm UTC](https://www.ruby-forum.com/t/ruby-question/90181 "2007-03-26T18:20:46Z")

</div>

Pardon my noobiness, but I’m learning both Ruby and Ror at the same time and am trying to understand Ruby a bit here. Say I have: class Ticket attr\_accessor :venue, :date def Test @venue = “Some Venue” @date = “03/…

---

## [Domain Specific Language security](https://www.ruby-forum.com/t/domain-specific-language-security/90176)

<div class="topic-metadata">

**Author:** [@dmcclean](https://www.ruby-forum.com/u/dmcclean)\
**Replies:** 2\
**Last updated:** [March 26, 2007, 5:42pm UTC](https://www.ruby-forum.com/t/domain-specific-language-security/90176 "2007-03-26T17:42:38Z")

</div>

Is there a way to write a DSL which limits the access by a user? Since this is Ruby, they could write any arbitrary expression such as MyModel.delete\_all My users would not do this on purpose, but perhaps by acciden…

---

## [Relocating an HTML element without rerendering anything?](https://www.ruby-forum.com/t/relocating-an-html-element-without-rerendering-anything/90169)

<div class="topic-metadata">

**Author:** [@danielb](https://www.ruby-forum.com/u/danielb)\
**Replies:** 1\
**Last updated:** [March 26, 2007, 5:41pm UTC](https://www.ruby-forum.com/t/relocating-an-html-element-without-rerendering-anything/90169 "2007-03-26T17:41:38Z")

</div>

Hey :slight\_smile: As some of you may know, I’m working on a drag-and-drop AJAX tree manager. I’ve got it pretty much done now, except for the dropping of one node onto another. I can relocate and save the node fine, …

---

## [Selective optimistic locking](https://www.ruby-forum.com/t/selective-optimistic-locking/90041)

<div class="topic-metadata">

**Author:** [@cinek](https://www.ruby-forum.com/u/cinek)\
**Replies:** 2\
**Last updated:** [March 26, 2007, 5:18pm UTC](https://www.ruby-forum.com/t/selective-optimistic-locking/90041 "2007-03-26T17:18:06Z")

</div>

I’m working on a photo gallery and use optimistic locking to prevent concurrent editing of photo description. At the same time I want to gather view statistics, incrementing a counter every time a user views a larger …

---

## [Sorting an array based on two attributes of objects](https://www.ruby-forum.com/t/sorting-an-array-based-on-two-attributes-of-objects/90166)

<div class="topic-metadata">

**Author:** [@senthil](https://www.ruby-forum.com/u/senthil)\
**Replies:** 1\
**Last updated:** [March 26, 2007, 5:01pm UTC](https://www.ruby-forum.com/t/sorting-an-array-based-on-two-attributes-of-objects/90166 "2007-03-26T17:01:22Z")

</div>

Thanks for some of your replies for the lst post i need small modification in that post … i want to sort the salary in descending order. i have explained the same quesion again… Hi all, I want to sort the objects of …

---

## [Adding AJAX 'Post a Comment' to blog](https://www.ruby-forum.com/t/adding-ajax-post-a-comment-to-blog/90089)

<div class="topic-metadata">

**Author:** [@casper\_the\_ghost](https://www.ruby-forum.com/u/casper_the_ghost)\
**Replies:** 2\
**Last updated:** [March 26, 2007, 4:59pm UTC](https://www.ruby-forum.com/t/adding-ajax-post-a-comment-to-blog/90089 "2007-03-26T16:59:21Z")

</div>

I am working a blog system for my girlfriend, and am trying to add AJAX to many places throughout the blog where refreshing is most troublesome; like when visitors post comments! Basically I have a text area for the c…

---

## [Active Record SQL View Support for SQL Server - Is this supp](https://www.ruby-forum.com/t/active-record-sql-view-support-for-sql-server-is-this-supp/89916)

<div class="topic-metadata">

**Author:** [@BrendanC](https://www.ruby-forum.com/u/BrendanC)\
**Replies:** 8\
**Last updated:** [March 26, 2007, 4:28pm UTC](https://www.ruby-forum.com/t/active-record-sql-view-support-for-sql-server-is-this-supp/89916 "2007-03-26T16:28:16Z")

</div>

I’m just exploring ROR for the first time - so excuse me if that has already been asked/answered. I’m intersted in developing a Web front end to an existing SQL Server database - migrating this to MySql/ Postgres is N…

---

## [Sorting the array](https://www.ruby-forum.com/t/sorting-the-array/90147)

<div class="topic-metadata">

**Author:** [@selvaraj](https://www.ruby-forum.com/u/selvaraj)\
**Replies:** 3\
**Last updated:** [March 26, 2007, 4:21pm UTC](https://www.ruby-forum.com/t/sorting-the-array/90147 "2007-03-26T16:21:11Z")

</div>

Hai I am facing the problem while try to sort. For example i have one object which is the result of query. That contains two field message and updated\_at.Same way i ahve another object with the same field. Now i have…

---

## [Sorting an array based on two attributes of objects](https://www.ruby-forum.com/t/sorting-an-array-based-on-two-attributes-of-objects/102725)

<div class="topic-metadata">

**Author:** [@senthil](https://www.ruby-forum.com/u/senthil)\
**Replies:** 2\
**Last updated:** [March 26, 2007, 4:00pm UTC](https://www.ruby-forum.com/t/sorting-an-array-based-on-two-attributes-of-objects/102725 "2007-03-26T16:00:11Z")

</div>

Hi all, I want to sort the objects of array based on two attributes.I want sort an employee class based on his salary and name , so that if two person has same salary it should be sorted with name. Lets say for examp…

---

## [Rails find Conditions](https://www.ruby-forum.com/t/rails-find-conditions/89899)

<div class="topic-metadata">

**Author:** [@mick](https://www.ruby-forum.com/u/mick)\
**Replies:** 2\
**Last updated:** [March 26, 2007, 3:53pm UTC](https://www.ruby-forum.com/t/rails-find-conditions/89899 "2007-03-26T15:53:50Z")

</div>

Hi, I am trying to return all the records in my table for which a date comparison reveals that that date is within 7 days. The code I have written looks like this: @subscriptions = find(:all, :conditions =\> \[‘subscrip…

---

## [L10n of numbers (i.e. decimal point)](https://www.ruby-forum.com/t/l10n-of-numbers-i-e-decimal-point/90162)

<div class="topic-metadata">

**Author:** [@Isak\_H](https://www.ruby-forum.com/u/Isak_H)\
**Replies:** 0\
**Last updated:** [March 26, 2007, 3:41pm UTC](https://www.ruby-forum.com/t/l10n-of-numbers-i-e-decimal-point/90162 "2007-03-26T15:41:07Z")

</div>

We need localized number format support in our application, in the very least being able to parse the native decimal point for numeric (Float and BigDecimal) fields. I’ve been spending some time looking at various plu…

---

## [Example Layouts](https://www.ruby-forum.com/t/example-layouts/90143)

<div class="topic-metadata">

**Author:** [@jim](https://www.ruby-forum.com/u/jim)\
**Replies:** 2\
**Last updated:** [March 26, 2007, 3:26pm UTC](https://www.ruby-forum.com/t/example-layouts/90143 "2007-03-26T15:26:51Z")

</div>

Hi wondering if there is any where I can get some nice looking layouts to use with my app. Thanks, Jim.

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

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