# Rails

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

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

---

## [Simple question about collections](https://www.ruby-forum.com/t/simple-question-about-collections/174555)

<div class="topic-metadata">

**Author:** [@trevoke](https://www.ruby-forum.com/u/trevoke)\
**Replies:** 2\
**Last updated:** [August 31, 2009, 2:50pm UTC](https://www.ruby-forum.com/t/simple-question-about-collections/174555 "2009-08-31T14:50:43Z")

</div>

Alright, so… Let’s try this: I have a view which one way or another calls a controller action and wants to update a div. This controller action finds a collection of records and does a render :partial with said c…

---

## [Users, Roles and Permissions](https://www.ruby-forum.com/t/users-roles-and-permissions/174618)

<div class="topic-metadata">

**Author:** [@Arne\_De\_Herdt](https://www.ruby-forum.com/u/Arne_De_Herdt)\
**Replies:** 2\
**Last updated:** [August 31, 2009, 2:36pm UTC](https://www.ruby-forum.com/t/users-roles-and-permissions/174618 "2009-08-31T14:36:49Z")

</div>

Hello, I’m currently working on a text-based roleplay browser game, and i’m trying to figure out what the best approach would be in order to create a system that allows me to assign roles to a user, and permissions …

---

## [List of installed gems](https://www.ruby-forum.com/t/list-of-installed-gems/174665)

<div class="topic-metadata">

**Author:** [@abhishek](https://www.ruby-forum.com/u/abhishek)\
**Replies:** 5\
**Last updated:** [August 31, 2009, 2:31pm UTC](https://www.ruby-forum.com/t/list-of-installed-gems/174665 "2009-08-31T14:31:31Z")

</div>

hi i have installed ruby 1.9.0 now when i type ‘gem list’, it shows: \*\*\* LOCAL GEMS \*\*\* how can i get the list of installed gems?? nd how can i check rails version? after installing ruby 1.9.0 my webrick server is …

---

## [Creating more than 1 child for an already existing parent](https://www.ruby-forum.com/t/creating-more-than-1-child-for-an-already-existing-parent/174671)

<div class="topic-metadata">

**Author:** [@akramwasim1234](https://www.ruby-forum.com/u/akramwasim1234)\
**Replies:** 8\
**Last updated:** [August 31, 2009, 1:52pm UTC](https://www.ruby-forum.com/t/creating-more-than-1-child-for-an-already-existing-parent/174671 "2009-08-31T13:52:55Z")

</div>

hi all, i have a parent by namr "consultancy" I want to create more than 1 child models for analready existing consultancy which has some extra feilds Plz help me in this regard.

---

## [Clearing warning in log](https://www.ruby-forum.com/t/clearing-warning-in-log/174684)

<div class="topic-metadata">

**Author:** [@bingobob](https://www.ruby-forum.com/u/bingobob)\
**Replies:** 5\
**Last updated:** [August 31, 2009, 1:52pm UTC](https://www.ruby-forum.com/t/clearing-warning-in-log/174684 "2009-08-31T13:52:55Z")

</div>

\<%= link\_to(\[image\_tag photo.data.url(:small)\],resort\_path(@resort)) %\> and i get this warning… warning: parenthesize argument(s) for future version it works but with the warning. All i’d like to do is just a link\_to…

---

## [My controller seems to have trouble finding the model](https://www.ruby-forum.com/t/my-controller-seems-to-have-trouble-finding-the-model/174679)

<div class="topic-metadata">

**Author:** [@jijiji](https://www.ruby-forum.com/u/jijiji)\
**Replies:** 2\
**Last updated:** [August 31, 2009, 12:49pm UTC](https://www.ruby-forum.com/t/my-controller-seems-to-have-trouble-finding-the-model/174679 "2009-08-31T12:49:40Z")

</div>

in my \\app\\controllers\\business\_controller.rb: class BusinessController \< ApplicationController def search @businesses = Business.search(params\[:businessname\], params\[:city\]) end end in my \\app\\models\\business.rb: …

---

## [Render action inside js template](https://www.ruby-forum.com/t/render-action-inside-js-template/174552)

<div class="topic-metadata">

**Author:** [@fabiokr](https://www.ruby-forum.com/u/fabiokr)\
**Replies:** 1\
**Last updated:** [August 31, 2009, 12:43pm UTC](https://www.ruby-forum.com/t/render-action-inside-js-template/174552 "2009-08-31T12:43:13Z")

</div>

Hello all, I’m trying to create the following: There is a index page that lists some items, and ‘new item’ button. I want the user to be able to click the button, and with ajax the page will be refreshed to show the …

---

## [Learning](https://www.ruby-forum.com/t/learning/174680)

<div class="topic-metadata">

**Author:** [@Prashu](https://www.ruby-forum.com/u/Prashu)\
**Replies:** 0\
**Last updated:** [August 31, 2009, 12:24pm UTC](https://www.ruby-forum.com/t/learning/174680 "2009-08-31T12:24:29Z")

</div>

I am working in cleartrip.com on ruy on rails ,so what are things i want to learn to become good developer on Ruby on Rails

---

## [Finally a blog post on Ruby on Rail naming conventions for the nuuubs~~](https://www.ruby-forum.com/t/finally-a-blog-post-on-ruby-on-rail-naming-conventions-for-the-nuuubs/174678)

<div class="topic-metadata">

**Author:** [@jijiji](https://www.ruby-forum.com/u/jijiji)\
**Replies:** 0\
**Last updated:** [August 31, 2009, 12:17pm UTC](https://www.ruby-forum.com/t/finally-a-blog-post-on-ruby-on-rail-naming-conventions-for-the-nuuubs/174678 "2009-08-31T12:17:26Z")

</div>

Just like to share the link http://itsignals.cascadia.com.au/?p=7

---

## [Nested each loops](https://www.ruby-forum.com/t/nested-each-loops/174673)

<div class="topic-metadata">

**Author:** [@brianp](https://www.ruby-forum.com/u/brianp)\
**Replies:** 0\
**Last updated:** [August 31, 2009, 10:45am UTC](https://www.ruby-forum.com/t/nested-each-loops/174673 "2009-08-31T10:45:30Z")

</div>

Hey, sorry for double post So I keep getting “undefined method \`each’ for #\<Definition: 0x28fa154\>”. The call that gets made returns 1 word object with 2 definition objects. I can verify both definition objects get r…

---

## [Controller Method ..?](https://www.ruby-forum.com/t/controller-method/171868)

<div class="topic-metadata">

**Author:** [@hemantborole](https://www.ruby-forum.com/u/hemantborole)\
**Replies:** 3\
**Last updated:** [August 31, 2009, 10:20am UTC](https://www.ruby-forum.com/t/controller-method/171868 "2009-08-31T10:20:23Z")

</div>

How to call a method of a controller into … another controller … another model … … Do u guys have any idea … ? …

---

## [InvalidAuthenticityToken](https://www.ruby-forum.com/t/invalidauthenticitytoken/174542)

<div class="topic-metadata">

**Author:** [@karthik](https://www.ruby-forum.com/u/karthik)\
**Replies:** 4\
**Last updated:** [August 31, 2009, 9:28am UTC](https://www.ruby-forum.com/t/invalidauthenticitytoken/174542 "2009-08-31T09:28:47Z")

</div>

Hi guys What does the below line says ActionController::InvalidAuthenticityToken (ActionController::InvalidAuthenticityToken): -e:2:in \`load’ -e:2 Please guide me – Karthik.k Mobile - +91-9894991640

---

## [Rmagick issue](https://www.ruby-forum.com/t/rmagick-issue/174534)

<div class="topic-metadata">

**Author:** [@arunvoip](https://www.ruby-forum.com/u/arunvoip)\
**Replies:** 2\
**Last updated:** [August 31, 2009, 9:11am UTC](https://www.ruby-forum.com/t/rmagick-issue/174534 "2009-08-31T09:11:49Z")

</div>

Hi all… i am working on rails version 1.2.3 (it is must to work on version 1.2.3) & ruby 1.8.6. For my project i want to convert text in to images files… so that i use rmagick… it is working fine for only english… i …

---

## [1 Form \> 2 Models \> 2nd Model Requres 1st Model ID](https://www.ruby-forum.com/t/1-form-2-models-2nd-model-requres-1st-model-id/174535)

<div class="topic-metadata">

**Author:** [@brianp](https://www.ruby-forum.com/u/brianp)\
**Replies:** 4\
**Last updated:** [August 31, 2009, 8:40am UTC](https://www.ruby-forum.com/t/1-form-2-models-2nd-model-requres-1st-model-id/174535 "2009-08-31T08:40:11Z")

</div>

Hey Everyone, So I have one form that submits information to create 2 models (A, B). I need the ID of model A to be inserted into model B. But the ID isn’t created until it hits the database (auto\_increment). But if f…

---

## [Calling same controller method from multiple site in radiant](https://www.ruby-forum.com/t/calling-same-controller-method-from-multiple-site-in-radiant/174659)

<div class="topic-metadata">

**Author:** [@mrbless](https://www.ruby-forum.com/u/mrbless)\
**Replies:** 0\
**Last updated:** [August 31, 2009, 7:48am UTC](https://www.ruby-forum.com/t/calling-same-controller-method-from-multiple-site-in-radiant/174659 "2009-08-31T07:48:05Z")

</div>

Hi all, I am using radiant cms with multiple site extension and shared layouts extension. My query is that how can i call the same controller method from two sites. My intension is to use only one ruby app and based o…

---

## [JRuby vs Ruby: why would you ever use ruby?](https://www.ruby-forum.com/t/jruby-vs-ruby-why-would-you-ever-use-ruby/173834)

<div class="topic-metadata">

**Author:** [@AlwaysCharging](https://www.ruby-forum.com/u/AlwaysCharging)\
**Replies:** 34\
**Last updated:** [August 31, 2009, 7:45am UTC](https://www.ruby-forum.com/t/jruby-vs-ruby-why-would-you-ever-use-ruby/173834 "2009-08-31T07:45:44Z")

</div>

Why would anyone use ruby over Jruby? I’m admittedly a noob about all this stuff, but from what I’ve read jruby seems superior to ruby and quite a bit faster. What would be the disadvantages of JRuby? I man it’s po…

---

## [What do these tags do \<%- xxxxxx -%\>](https://www.ruby-forum.com/t/what-do-these-tags-do-xxxxxx/174649)

<div class="topic-metadata">

**Author:** [@jyothsna](https://www.ruby-forum.com/u/jyothsna)\
**Replies:** 2\
**Last updated:** [August 31, 2009, 7:00am UTC](https://www.ruby-forum.com/t/what-do-these-tags-do-xxxxxx/174649 "2009-08-31T07:00:46Z")

</div>

Hi, I see some code from some open source project. in many of the view files(.erb) , I see the following statements. Idont understand how they are interpreted… are they comments, or shown on UI, or just executed? \<%…

---

## [TinyMCE and image upload](https://www.ruby-forum.com/t/tinymce-and-image-upload/111553)

<div class="topic-metadata">

**Author:** [@apie](https://www.ruby-forum.com/u/apie)\
**Replies:** 10\
**Last updated:** [August 31, 2009, 2:40am UTC](https://www.ruby-forum.com/t/tinymce-and-image-upload/111553 "2009-08-31T02:40:12Z")

</div>

Hi All Im using Blake’s tinyMCE plugin. I want to add image upload functionality or at least image browse - the standard tinyMCE image pop-up doesn’t really provide for a great user experience. What is the best rout…

---

## [Does paperclip set width and height of images?](https://www.ruby-forum.com/t/does-paperclip-set-width-and-height-of-images/174646)

<div class="topic-metadata">

**Author:** [@fipa](https://www.ruby-forum.com/u/fipa)\
**Replies:** 1\
**Last updated:** [August 31, 2009, 2:23am UTC](https://www.ruby-forum.com/t/does-paperclip-set-width-and-height-of-images/174646 "2009-08-31T02:23:50Z")

</div>

It’s all in the title= I don’t remember if xxx\_width and xxx\_height are magic columns that paperclip would automatically fill if ImageMagick can handle the upload. It seems no to me, but that would be so easy to add…

---

## [Snow leopard + pg gem](https://www.ruby-forum.com/t/snow-leopard-pg-gem/174640)

<div class="topic-metadata">

**Author:** [@jai](https://www.ruby-forum.com/u/jai)\
**Replies:** 2\
**Last updated:** [August 31, 2009, 12:39am UTC](https://www.ruby-forum.com/t/snow-leopard-pg-gem/174640 "2009-08-31T00:39:08Z")

</div>

Hi, I installed snow leopard on my machine and my ruby on rails project stopped working… When I tried script/server I this error Booting WEBrick =\> Rails 2.3.3 application starting on http://0.0.0.0:3000 /Library/…

---

## [Time.today?](https://www.ruby-forum.com/t/time-today/174574)

<div class="topic-metadata">

**Author:** [@fipa](https://www.ruby-forum.com/u/fipa)\
**Replies:** 12\
**Last updated:** [August 30, 2009, 11:34pm UTC](https://www.ruby-forum.com/t/time-today/174574 "2009-08-30T23:34:41Z")

</div>

Hi, Time.today fails on my server and works on my dev machine, both run Rails 2.3.3. What’s going on?

---

## [Instrumenting rails response times with cache-money](https://www.ruby-forum.com/t/instrumenting-rails-response-times-with-cache-money/174642)

<div class="topic-metadata">

**Author:** [@spidaman](https://www.ruby-forum.com/u/spidaman)\
**Replies:** 0\
**Last updated:** [August 30, 2009, 9:15pm UTC](https://www.ruby-forum.com/t/instrumenting-rails-response-times-with-cache-money/174642 "2009-08-30T21:15:57Z")

</div>

I’m trying to chase down intermittent production performance problems. I see entries like this in app log Completed in 196ms (View: 22, DB: 7) which is a fine start but I’m looking for details such cache-money hit/ m…

---

## [Force lowercase username in a model](https://www.ruby-forum.com/t/force-lowercase-username-in-a-model/104887)

<div class="topic-metadata">

**Author:** [@Tirta\_KSUntario](https://www.ruby-forum.com/u/Tirta_KSUntario)\
**Replies:** 9\
**Last updated:** [August 30, 2009, 8:38pm UTC](https://www.ruby-forum.com/t/force-lowercase-username-in-a-model/104887 "2009-08-30T20:38:53Z")

</div>

Hi guys, I ran into small problem here, but couldn’t find the solution anywhere. I have this model: create\_table :users do |t| t.column "username", :string t.column "email", :string t.column "passw…

---

## [Status of various RoR releases](https://www.ruby-forum.com/t/status-of-various-ror-releases/174595)

<div class="topic-metadata">

**Author:** [@piegut](https://www.ruby-forum.com/u/piegut)\
**Replies:** 1\
**Last updated:** [August 30, 2009, 7:01pm UTC](https://www.ruby-forum.com/t/status-of-various-ror-releases/174595 "2009-08-30T19:01:53Z")

</div>

Hi All, I was thinking about adding a page to the RoR wiki that had a list of RoR release versions, and a status for each. (This all stemmed from me wanting to release a 2.2.2 app when 2.3.3 is current, and not havin…

---

## [Need version 2.1.0 of SQL Server adapter for Rails](https://www.ruby-forum.com/t/need-version-2-1-0-of-sql-server-adapter-for-rails/174619)

<div class="topic-metadata">

**Author:** [@weyus](https://www.ruby-forum.com/u/weyus)\
**Replies:** 1\
**Last updated:** [August 30, 2009, 6:41pm UTC](https://www.ruby-forum.com/t/need-version-2-1-0-of-sql-server-adapter-for-rails/174619 "2009-08-30T18:41:24Z")

</div>

Is there any place that I can get versions of the SQL Server adapter for Rails that are \<= 2.1.0? I’ve looked at Rails SQL Server · GitHub and the oldest version there appears to be 2.2. Thanks, Wes

---

## [Problems with MySQL Installation](https://www.ruby-forum.com/t/problems-with-mysql-installation/174597)

<div class="topic-metadata">

**Author:** [@urmel1960](https://www.ruby-forum.com/u/urmel1960)\
**Replies:** 4\
**Last updated:** [August 30, 2009, 3:34pm UTC](https://www.ruby-forum.com/t/problems-with-mysql-installation/174597 "2009-08-30T15:34:46Z")

</div>

Hello: I am trying to get rails up and running with mysql for a redmine installation. When I try to install the mysql gem, I get the following: h1605521:/ # gem install mysql Building native extensions. This could …

---

## [HAML problem on hosting](https://www.ruby-forum.com/t/haml-problem-on-hosting/174631)

<div class="topic-metadata">

**Author:** [@dhruvasagar](https://www.ruby-forum.com/u/dhruvasagar)\
**Replies:** 1\
**Last updated:** [August 30, 2009, 1:44pm UTC](https://www.ruby-forum.com/t/haml-problem-on-hosting/174631 "2009-08-30T13:44:37Z")

</div>

I am using HAML, i’ve been using it since quite sometime, but I haven’t worked with actually deploying applications to web hostings. Currently I am trying to host my application to a hostmonster webhosting that I own,…

---

## [Rails Deployment](https://www.ruby-forum.com/t/rails-deployment/174632)

<div class="topic-metadata">

**Author:** [@dhruvasagar](https://www.ruby-forum.com/u/dhruvasagar)\
**Replies:** 1\
**Last updated:** [August 30, 2009, 1:28pm UTC](https://www.ruby-forum.com/t/rails-deployment/174632 "2009-08-30T13:28:49Z")

</div>

Hi, How do I configure my rails app for a custom gems directory ? My hosting tells me that I need to add this to my scripts : $:.push(“/home/concptpl/ruby/gems”) But that seems to be for independent ruby scripts, how…

---

## [Can non-ActiveRecord variables be temporarily stored in a class?](https://www.ruby-forum.com/t/can-non-activerecord-variables-be-temporarily-stored-in-a-class/174261)

<div class="topic-metadata">

**Author:** [@coolaj86](https://www.ruby-forum.com/u/coolaj86)\
**Replies:** 8\
**Last updated:** [August 30, 2009, 12:48pm UTC](https://www.ruby-forum.com/t/can-non-activerecord-variables-be-temporarily-stored-in-a-class/174261 "2009-08-30T12:48:26Z")

</div>

I’m creating a PDF directory using PDF::Writer. The directory has a few pieces. The photo directory is sorted by group The appendix is sorted by last name I want the appendix to show the page number on which the pers…

---

## [How to mock block](https://www.ruby-forum.com/t/how-to-mock-block/174627)

<div class="topic-metadata">

**Author:** [@flyerhzm](https://www.ruby-forum.com/u/flyerhzm)\
**Replies:** 0\
**Last updated:** [August 30, 2009, 8:54am UTC](https://www.ruby-forum.com/t/how-to-mock-block/174627 "2009-08-30T08:54:53Z")

</div>

I have written the following codes: uri = URI.parse(page\_url) response = Net::HTTP.start(uri.host, uri.port) do |http| http.get(uri.request\_uri, headers) end How can mock it with different uri.request\_uri and return…

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

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