# Rails

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

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

---

## [File missing](https://www.ruby-forum.com/t/file-missing/150825)

<div class="topic-metadata">

**Author:** [@Raistlin\_M](https://www.ruby-forum.com/u/Raistlin_M)\
**Replies:** 4\
**Last updated:** [October 13, 2008, 9:52pm UTC](https://www.ruby-forum.com/t/file-missing/150825 "2008-10-13T21:52:13Z")

</div>

Do you have a rails.cmd or a rails.bat at C:\\ruby\\bin? I have a rails.bat, but not a rails.cmd! I am wondering if I accidentally deleted rails.cmd! What do you say?

---

## [How do you manage Access Control?](https://www.ruby-forum.com/t/how-do-you-manage-access-control/148133)

<div class="topic-metadata">

**Author:** [@max](https://www.ruby-forum.com/u/max)\
**Replies:** 7\
**Last updated:** [October 13, 2008, 9:50pm UTC](https://www.ruby-forum.com/t/how-do-you-manage-access-control/148133 "2008-10-13T21:50:27Z")

</div>

I’m working on a rather large app, where we have more than 7 user roles, each of which will have permission to access different parts of the application. Now the User/Admin system is falling short so I need to redefin…

---

## [Association Methods](https://www.ruby-forum.com/t/association-methods/150785)

<div class="topic-metadata">

**Author:** [@jette](https://www.ruby-forum.com/u/jette)\
**Replies:** 14\
**Last updated:** [October 13, 2008, 9:23pm UTC](https://www.ruby-forum.com/t/association-methods/150785 "2008-10-13T21:23:56Z")

</div>

I am a newbie of ruby on rails. And I have met a problem with model association. I have 2 tables here, one is “item” the other is “brand”, when I create one new item, I want to select one brand from the list. Here ar…

---

## [SSL Slow Loads with ssl\_required](https://www.ruby-forum.com/t/ssl-slow-loads-with-ssl-required/150824)

<div class="topic-metadata">

**Author:** [@casper\_the\_ghost](https://www.ruby-forum.com/u/casper_the_ghost)\
**Replies:** 0\
**Last updated:** [October 13, 2008, 9:08pm UTC](https://www.ruby-forum.com/t/ssl-slow-loads-with-ssl-required/150824 "2008-10-13T21:08:06Z")

</div>

This problem has had me stumped for three days now, and I’m really running short on ideas. Really hope somebody else out there has some expertise on the mysterious ways of the SSL. I’m running a Rails 2.0.2 Mongrel c…

---

## [Internal server error after editing environment.rb](https://www.ruby-forum.com/t/internal-server-error-after-editing-environment-rb/150762)

<div class="topic-metadata">

**Author:** [@tomzoo](https://www.ruby-forum.com/u/tomzoo)\
**Replies:** 3\
**Last updated:** [October 13, 2008, 8:28pm UTC](https://www.ruby-forum.com/t/internal-server-error-after-editing-environment-rb/150762 "2008-10-13T20:28:46Z")

</div>

Hi all, this is hopefully a quick one for gurus. I edited my environment.rb file, commenting out these lines: config.action\_controller.session = { :session\_key =\> ‘\_test\_session’, :secret =\> ‘long key here’ } …

---

## [Mongrel process spinning with CPU & MEM maxed out](https://www.ruby-forum.com/t/mongrel-process-spinning-with-cpu-mem-maxed-out/150399)

<div class="topic-metadata">

**Author:** [@chovy](https://www.ruby-forum.com/u/chovy)\
**Replies:** 11\
**Last updated:** [October 13, 2008, 7:46pm UTC](https://www.ruby-forum.com/t/mongrel-process-spinning-with-cpu-mem-maxed-out/150399 "2008-10-13T19:46:50Z")

</div>

PID USER PR NI VIRT RES SHR S %CPU %MEM TIME+ PPID COMMAND 12565 ettinger 39 0 1110m 1.1g 2680 R 99.9 54.4 21:53.77 1 /usr/bin/ruby1.8 /usr/bin/mongrel\_rails start -C /home/ettinger/directoryofd…

---

## [Any status of the book "Agile Testing With Ruby and Rails"?](https://www.ruby-forum.com/t/any-status-of-the-book-agile-testing-with-ruby-and-rails/150735)

<div class="topic-metadata">

**Author:** [@Hunt\_J](https://www.ruby-forum.com/u/Hunt_J)\
**Replies:** 1\
**Last updated:** [October 13, 2008, 7:14pm UTC](https://www.ruby-forum.com/t/any-status-of-the-book-agile-testing-with-ruby-and-rails/150735 "2008-10-13T19:14:27Z")

</div>

Does anybody know if the book is really being published? http://www.amazon.co.uk/dp/1590599152/ I’ve been waiting for a while, but looks like the schedule is put off over and over. Can anybody recommend good resource…

---

## [Ditto! Any solutions?](https://www.ruby-forum.com/t/ditto-any-solutions/150819)

<div class="topic-metadata">

**Author:** [@vaibhav](https://www.ruby-forum.com/u/vaibhav)\
**Replies:** 0\
**Last updated:** [October 13, 2008, 7:09pm UTC](https://www.ruby-forum.com/t/ditto-any-solutions/150819 "2008-10-13T19:09:47Z")

</div>

Hi, I’m facing the same problem. I remember using google apps properly on windows but its giving this error on Ubuntu Hardy Any suggestions? Thanks, –Vaibhav

---

## [Searching on two table fields](https://www.ruby-forum.com/t/searching-on-two-table-fields/150810)

<div class="topic-metadata">

**Author:** [@martinevans](https://www.ruby-forum.com/u/martinevans)\
**Replies:** 4\
**Last updated:** [October 13, 2008, 6:38pm UTC](https://www.ruby-forum.com/t/searching-on-two-table-fields/150810 "2008-10-13T18:38:38Z")

</div>

i have a recipe table id recipe\_title diet\_id meal\_id I have set up the associations and can create, edit and delete recipes no problem. I have set up navigation with a list of diets for example low carb, high fi…

---

## [Open a modal window for registration](https://www.ruby-forum.com/t/open-a-modal-window-for-registration/150799)

<div class="topic-metadata">

**Author:** [@medwedj](https://www.ruby-forum.com/u/medwedj)\
**Replies:** 1\
**Last updated:** [October 13, 2008, 5:32pm UTC](https://www.ruby-forum.com/t/open-a-modal-window-for-registration/150799 "2008-10-13T17:32:14Z")

</div>

Hello, all! As first: am a newbie in RoR. The problem is: I need a modal widow to show some registration fields for my site. There is a main window with a button “Register” on it. After pressing the button the user …

---

## [\<false\> is not true failure in unit test](https://www.ruby-forum.com/t/false-is-not-true-failure-in-unit-test/150730)

<div class="topic-metadata">

**Author:** [@jicksta](https://www.ruby-forum.com/u/jicksta)\
**Replies:** 11\
**Last updated:** [October 13, 2008, 5:04pm UTC](https://www.ruby-forum.com/t/false-is-not-true-failure-in-unit-test/150730 "2008-10-13T17:04:59Z")

</div>

Hi, I’ve done as follows: MODEL: class Fee \< ActiveRecord::Base has\_many :campsites validates\_presence\_of :per\_person\_rate, :family\_rate validates\_numericality\_of :per\_person\_rate, :family\_rate def validate errors.…

---

## [Multiple Models on a Single Form](https://www.ruby-forum.com/t/multiple-models-on-a-single-form/150807)

<div class="topic-metadata">

**Author:** [@nibbler61](https://www.ruby-forum.com/u/nibbler61)\
**Replies:** 1\
**Last updated:** [October 13, 2008, 4:42pm UTC](https://www.ruby-forum.com/t/multiple-models-on-a-single-form/150807 "2008-10-13T16:42:14Z")

</div>

I can’t figure out why this wont work for creating the items and tie them to the po id number http://pastie.org/291223

---

## [How to update the extra field of relationship table when use have\_many :throuth effectively](https://www.ruby-forum.com/t/how-to-update-the-extra-field-of-relationship-table-when-use-have-many-throuth-effectively/150796)

<div class="topic-metadata">

**Author:** [@guofeng](https://www.ruby-forum.com/u/guofeng)\
**Replies:** 1\
**Last updated:** [October 13, 2008, 4:09pm UTC](https://www.ruby-forum.com/t/how-to-update-the-extra-field-of-relationship-table-when-use-have-many-throuth-effectively/150796 "2008-10-13T16:09:12Z")

</div>

I defined the relationship of two tables as below: Programme(id,code,name) Course(id,code,name) ProgarmmeCourse(id,programme\_id,course\_id,status) class Programme \< ActiveRecord::Base has\_many :programme\_courses,:dep…

---

## [To understand the flow of application in ror](https://www.ruby-forum.com/t/to-understand-the-flow-of-application-in-ror/150719)

<div class="topic-metadata">

**Author:** [@tanmay](https://www.ruby-forum.com/u/tanmay)\
**Replies:** 2\
**Last updated:** [October 13, 2008, 3:15pm UTC](https://www.ruby-forum.com/t/to-understand-the-flow-of-application-in-ror/150719 "2008-10-13T15:15:06Z")

</div>

hi every one i am new in this platform and seeking for help . i have created a small application which runs quite well but actually i dont know how it flows when and where the method calls itself. i know every reques…

---

## [How to create test data using migration for file\_column](https://www.ruby-forum.com/t/how-to-create-test-data-using-migration-for-file-column/150771)

<div class="topic-metadata">

**Author:** [@casensio](https://www.ruby-forum.com/u/casensio)\
**Replies:** 1\
**Last updated:** [October 13, 2008, 3:05pm UTC](https://www.ruby-forum.com/t/how-to-create-test-data-using-migration-for-file-column/150771 "2008-10-13T15:05:06Z")

</div>

Hi, i would like to create test data for my client using migration. for example: Model.create( :name =\> ‘john’, :age =\> ‘28’ ) how would one do that for the file\_column “image” field? i have tried to give the nam…

---

## [Focus problem](https://www.ruby-forum.com/t/focus-problem/150798)

<div class="topic-metadata">

**Author:** [@mikael](https://www.ruby-forum.com/u/mikael)\
**Replies:** 0\
**Last updated:** [October 13, 2008, 2:15pm UTC](https://www.ruby-forum.com/t/focus-problem/150798 "2008-10-13T14:15:28Z")

</div>

Hi! When my form loads i have a setFocus to the first textarea. Then when i use the tab-key it will go to the second textarea for all browsers except IE6. IE6 jumps to my sidebar where i have advertisments. How can i…

---

## [Patching auto\_link for @username link conversion](https://www.ruby-forum.com/t/patching-auto-link-for-username-link-conversion/150791)

<div class="topic-metadata">

**Author:** [@chunkyslink](https://www.ruby-forum.com/u/chunkyslink)\
**Replies:** 2\
**Last updated:** [October 13, 2008, 1:06pm UTC](https://www.ruby-forum.com/t/patching-auto-link-for-username-link-conversion/150791 "2008-10-13T13:06:01Z")

</div>

Does anyone know of an easy way to convert a unique ‘@username’ (i.e. @user.username) using an auto\_link-esque helper? I have a method for doing it on the way in to the database but, I realise there’s a few deal break…

---

## [Virtual attribute setter method in model, how to write a scoped query?](https://www.ruby-forum.com/t/virtual-attribute-setter-method-in-model-how-to-write-a-scoped-query/150677)

<div class="topic-metadata">

**Author:** [@vinay](https://www.ruby-forum.com/u/vinay)\
**Replies:** 1\
**Last updated:** [October 13, 2008, 12:58pm UTC](https://www.ruby-forum.com/t/virtual-attribute-setter-method-in-model-how-to-write-a-scoped-query/150677 "2008-10-13T12:58:31Z")

</div>

I have a form that has a virtual attribute ‘contact\_name’. In the setter method for this, I need to scope the query through current\_user.contacts.find (etc). But current\_user is a helper method (RESTful authentication…

---

## [Newbie question about running mysql](https://www.ruby-forum.com/t/newbie-question-about-running-mysql/150783)

<div class="topic-metadata">

**Author:** [@Raheem](https://www.ruby-forum.com/u/Raheem)\
**Replies:** 1\
**Last updated:** [October 13, 2008, 12:34pm UTC](https://www.ruby-forum.com/t/newbie-question-about-running-mysql/150783 "2008-10-13T12:34:27Z")

</div>

Hello, I am following the Agile Rails dev book and I like the command line format used to create example apps in the book. However, I am stuck on one point. How do I run mysql commands from the Rails prompt. I have a …

---

## [Observing few fields in a form - Best Practise?](https://www.ruby-forum.com/t/observing-few-fields-in-a-form-best-practise/150671)

<div class="topic-metadata">

**Author:** [@vinay](https://www.ruby-forum.com/u/vinay)\
**Replies:** 8\
**Last updated:** [October 13, 2008, 11:46am UTC](https://www.ruby-forum.com/t/observing-few-fields-in-a-form-best-practise/150671 "2008-10-13T11:46:55Z")

</div>

Hi, im looking to build a page similar to a shopping cart page. When you change the ‘price’ or ‘quantity’ fields, the total is calculated and displayed. There are other fields in the form which have no relation to th…

---

## [\[JOBS\] I am C/C++ guy and a Ruby newbie I am looking for a job in Ruby/RoR](https://www.ruby-forum.com/t/jobs-i-am-c-c-guy-and-a-ruby-newbie-i-am-looking-for-a-job-in-ruby-ror/150319)

<div class="topic-metadata">

**Author:** [@the69geeks](https://www.ruby-forum.com/u/the69geeks)\
**Replies:** 3\
**Last updated:** [October 13, 2008, 11:23am UTC](https://www.ruby-forum.com/t/jobs-i-am-c-c-guy-and-a-ruby-newbie-i-am-looking-for-a-job-in-ruby-ror/150319 "2008-10-13T11:23:23Z")

</div>

Hi All, I am working with Capgemini Consulting India, Mumbai for more than 2.5 years. I am mainly in restructuring Legacy Retail applications for a similar look with increased maintainability. I was amazed by Ruby an…

---

## [Routes problem](https://www.ruby-forum.com/t/routes-problem/150782)

<div class="topic-metadata">

**Author:** [@gdiazl](https://www.ruby-forum.com/u/gdiazl)\
**Replies:** 1\
**Last updated:** [October 13, 2008, 11:01am UTC](https://www.ruby-forum.com/t/routes-problem/150782 "2008-10-13T11:01:41Z")

</div>

Hello, Just a single problem i can’t solve. The scenario… I have a controller called “places” but i don’t want to link the users to /places/whatever, i want something like /no/whatever. How to achieve this? I have i…

---

## [Spennende prosjekter i Norge og internasjonalt](https://www.ruby-forum.com/t/spennende-prosjekter-i-norge-og-internasjonalt/150790)

<div class="topic-metadata">

**Author:** [@Magnar](https://www.ruby-forum.com/u/Magnar)\
**Replies:** 0\
**Last updated:** [October 13, 2008, 10:49am UTC](https://www.ruby-forum.com/t/spennende-prosjekter-i-norge-og-internasjonalt/150790 "2008-10-13T10:49:22Z")

</div>

Er interessert i å komme i kontakt med norske utviklere av Ruby on Rails-løsninger. Har en rekke spennende løsninger både nasjonalt i Norge, og internasjonalt som det er gode penger i. Ta kontakt om du vil bli med so…

---

## [How would you know how to call this rails method (select\_all) this starting point of it's Rails API](https://www.ruby-forum.com/t/how-would-you-know-how-to-call-this-rails-method-select-all-this-starting-point-of-its-rails-api/150733)

<div class="topic-metadata">

**Author:** [@greg](https://www.ruby-forum.com/u/greg)\
**Replies:** 3\
**Last updated:** [October 13, 2008, 9:40am UTC](https://www.ruby-forum.com/t/how-would-you-know-how-to-call-this-rails-method-select-all-this-starting-point-of-its-rails-api/150733 "2008-10-13T09:40:40Z")

</div>

Hi, I’m curious. If you saw the Rails “select\_all(sql, name = nil)” method (rerfer ActiveRecord::ConnectionAdapters::DatabaseStatements), and wanted to use it, how would you really know how to use it and call it …

---

## [Has\_many / belongs\_to associations](https://www.ruby-forum.com/t/has-many-belongs-to-associations/149556)

<div class="topic-metadata">

**Author:** [@jon](https://www.ruby-forum.com/u/jon)\
**Replies:** 7\
**Last updated:** [October 13, 2008, 9:34am UTC](https://www.ruby-forum.com/t/has-many-belongs-to-associations/149556 "2008-10-13T09:34:46Z")

</div>

I have two models, Review and Album. Album has many reviews, and Review belongs to Album as seen below in their respective model files. class Review \< ActiveRecord::Base belongs\_to :album end class Album \< ActiveRe…

---

## [\[JOBS\] RoR Contract Opportunity](https://www.ruby-forum.com/t/jobs-ror-contract-opportunity/150780)

<div class="topic-metadata">

**Author:** [@BrandonM](https://www.ruby-forum.com/u/BrandonM)\
**Replies:** 0\
**Last updated:** [October 13, 2008, 9:34am UTC](https://www.ruby-forum.com/t/jobs-ror-contract-opportunity/150780 "2008-10-13T09:34:11Z")

</div>

\[Overview\] We’re a stealth startup, New York-based online social network & resource site for the book industry. We operate a community that allows book readers to connect, share, discuss, and discover books with othe…

---

## [JOBS - I'm looking for Senior/Creative RR developers](https://www.ruby-forum.com/t/jobs-im-looking-for-senior-creative-rr-developers/150781)

<div class="topic-metadata">

**Author:** [@casper\_the\_ghost](https://www.ruby-forum.com/u/casper_the_ghost)\
**Replies:** 0\
**Last updated:** [October 13, 2008, 9:34am UTC](https://www.ruby-forum.com/t/jobs-im-looking-for-senior-creative-rr-developers/150781 "2008-10-13T09:34:11Z")

</div>

Hi I’m looking for 3 Senior/Creative Ruby on Rails developers/programmers to join an early stage startup up team. - Ruby/JavaScript programmers interested in pair-programming, test-driven development, and iterative d…

---

## [HABTM & CheckBoxes](https://www.ruby-forum.com/t/habtm-checkboxes/150775)

<div class="topic-metadata">

**Author:** [@Davo](https://www.ruby-forum.com/u/Davo)\
**Replies:** 3\
**Last updated:** [October 13, 2008, 7:52am UTC](https://www.ruby-forum.com/t/habtm-checkboxes/150775 "2008-10-13T07:52:17Z")

</div>

I’m trying to achieve something that I assume is fairly common? I have a Category table and a Brand Table. When I create a new Category I want a list of checkboxes to appear, and when checked they update the category\_…

---

## [Use of custom routings](https://www.ruby-forum.com/t/use-of-custom-routings/150434)

<div class="topic-metadata">

**Author:** [@mokkai](https://www.ruby-forum.com/u/mokkai)\
**Replies:** 3\
**Last updated:** [October 13, 2008, 7:20am UTC](https://www.ruby-forum.com/t/use-of-custom-routings/150434 "2008-10-13T07:20:36Z")

</div>

what is the main use of 1)map.resources 2)nested resources 3)if we use only map.connect ‘:controller/:action/:id’ map.connect ‘:controller/:action/:id.:format’ in routes.rb ,then what is the drawback of that ? can…

---

## [Determining which controller to write the code into!](https://www.ruby-forum.com/t/determining-which-controller-to-write-the-code-into/150605)

<div class="topic-metadata">

**Author:** [@chirantan](https://www.ruby-forum.com/u/chirantan)\
**Replies:** 2\
**Last updated:** [October 13, 2008, 6:19am UTC](https://www.ruby-forum.com/t/determining-which-controller-to-write-the-code-into/150605 "2008-10-13T06:19:17Z")

</div>

This question is more about how things work in an MVC architecture based ORM application. I want to know which controller to write code into when there is a many to many relationship between 2 models. Example, I have…

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

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