# Rails

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

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

---

## [\[ANN\] released Zena CMS 0.16.5](https://www.ruby-forum.com/t/ann-released-zena-cms-0-16-5/187019)

<div class="topic-metadata">

**Author:** [@gazoduc](https://www.ruby-forum.com/u/gazoduc)\
**Replies:** 2\
**Last updated:** [April 19, 2010, 9:28am UTC](https://www.ruby-forum.com/t/ann-released-zena-cms-0-16-5/187019 "2010-04-19T09:28:41Z")

</div>

Hi list ! This is a bug fix release of the coolest CMS around (yes, I am biased). http://bit.ly/bYm7Rm I hope this is the last release on the 0.16.x branch and we can move to the 1.0 branch because there are really e…

---

## [Get subdomain from action controller](https://www.ruby-forum.com/t/get-subdomain-from-action-controller/187169)

<div class="topic-metadata">

**Author:** [@builtbysimple](https://www.ruby-forum.com/u/builtbysimple)\
**Replies:** 2\
**Last updated:** [April 19, 2010, 8:37am UTC](https://www.ruby-forum.com/t/get-subdomain-from-action-controller/187169 "2010-04-19T08:37:10Z")

</div>

Hi all, Is it possible to get the subdomain of the request from the action controller? If so, how do we get the subdomain from Rails action controller? I tried to look at the Rails guide about this but can not find a…

---

## [Forcing link\_to 'put'](https://www.ruby-forum.com/t/forcing-link-to-put/186978)

<div class="topic-metadata">

**Author:** [@markb](https://www.ruby-forum.com/u/markb)\
**Replies:** 7\
**Last updated:** [April 19, 2010, 6:53am UTC](https://www.ruby-forum.com/t/forcing-link-to-put/186978 "2010-04-19T06:53:35Z")

</div>

I cannot force my link\_to statement to send an HTTP put into my controller’s update method. It appears to be using get and therefore invoking the show method. Here is what my view looks like (I am using nested resou…

---

## [Change names easily](https://www.ruby-forum.com/t/change-names-easily/187158)

<div class="topic-metadata">

**Author:** [@yijisoo](https://www.ruby-forum.com/u/yijisoo)\
**Replies:** 1\
**Last updated:** [April 19, 2010, 6:35am UTC](https://www.ruby-forum.com/t/change-names-easily/187158 "2010-04-19T06:35:26Z")

</div>

How can I change a name of controller or model all together… It turns out to be a big hassle because names are important in linking source codes (e.g., model names are linked with database structure and controller are…

---

## [Rails form field to ask for directory to download to](https://www.ruby-forum.com/t/rails-form-field-to-ask-for-directory-to-download-to/187163)

<div class="topic-metadata">

**Author:** [@pitosalas](https://www.ruby-forum.com/u/pitosalas)\
**Replies:** 3\
**Last updated:** [April 19, 2010, 1:04am UTC](https://www.ruby-forum.com/t/rails-form-field-to-ask-for-directory-to-download-to/187163 "2010-04-19T01:04:12Z")

</div>

Hi all, I need a way to ask a user to supply a directory on their computer (i.e. client) to which to download a series of files. So in other words, the user is asked: Please indicate directory to download to: … And …

---

## [Time\_zone\_select :priority\_zones not working properly](https://www.ruby-forum.com/t/time-zone-select-priority-zones-not-working-properly/187090)

<div class="topic-metadata">

**Author:** [@anthonys](https://www.ruby-forum.com/u/anthonys)\
**Replies:** 1\
**Last updated:** [April 19, 2010, 12:05am UTC](https://www.ruby-forum.com/t/time-zone-select-priority-zones-not-working-properly/187090 "2010-04-19T00:05:39Z")

</div>

I sent this earlier but I don’t think it ever came through. Sorry if this is a reposting. When using :priority\_zones for time\_zone\_select in a manner described by the API docs for ActionView::Helpers::FormOptionsHelpe…

---

## [Rails on nginx/passenger/xubuntu error](https://www.ruby-forum.com/t/rails-on-nginx-passenger-xubuntu-error/187160)

<div class="topic-metadata">

**Author:** [@badnaam](https://www.ruby-forum.com/u/badnaam)\
**Replies:** 0\
**Last updated:** [April 18, 2010, 9:46pm UTC](https://www.ruby-forum.com/t/rails-on-nginx-passenger-xubuntu-error/187160 "2010-04-18T21:46:20Z")

</div>

I just installed latest rails, passenger, nginx on xubuntu. I deployed a static app (myapp) on port 80 and it seems to work fine. I installed fast-cgi and deployed phpmyadmin on 8888 which works fine. Then I tried to …

---

## [Updating Schema](https://www.ruby-forum.com/t/updating-schema/187156)

<div class="topic-metadata">

**Author:** [@paragadosm](https://www.ruby-forum.com/u/paragadosm)\
**Replies:** 2\
**Last updated:** [April 18, 2010, 9:34pm UTC](https://www.ruby-forum.com/t/updating-schema/187156 "2010-04-18T21:34:02Z")

</div>

Hey, i was thinking about “creating-multiple-associations-with-the-same-table” and found this: ive done everything as written but how can i tell ruby to update by database schema? player: id name challenge: P1 …

---

## [Rails 3 environment?](https://www.ruby-forum.com/t/rails-3-environment/187145)

<div class="topic-metadata">

**Author:** [@tenshi](https://www.ruby-forum.com/u/tenshi)\
**Replies:** 1\
**Last updated:** [April 18, 2010, 8:10pm UTC](https://www.ruby-forum.com/t/rails-3-environment/187145 "2010-04-18T20:10:56Z")

</div>

Hi all, I want to start trying Rails 3 but I can’t find the ideal environment for it. Have already tryed ruby 1.8.7, 1.9.1 and 1.9.2 and all of it seems to crash with something related to rails 3. So I’m just wonder…

---

## [Localhost:3000/en/x instead of localhost:3000/x?locale=en](https://www.ruby-forum.com/t/localhost-3000-en-x-instead-of-localhost-3000-x-locale-en/187117)

<div class="topic-metadata">

**Author:** [@taranaki](https://www.ruby-forum.com/u/taranaki)\
**Replies:** 2\
**Last updated:** [April 18, 2010, 7:25pm UTC](https://www.ruby-forum.com/t/localhost-3000-en-x-instead-of-localhost-3000-x-locale-en/187117 "2010-04-18T19:25:52Z")

</div>

Hello everyone At first I have to say that I am quite new to Ruby on Rails. Now I have encountered the following problem. My application (which is something similar to a library system and quite big) is able to chang…

---

## [Rails 3: new namespace inside nested resource?](https://www.ruby-forum.com/t/rails-3-new-namespace-inside-nested-resource/187152)

<div class="topic-metadata">

**Author:** [@anr](https://www.ruby-forum.com/u/anr)\
**Replies:** 0\
**Last updated:** [April 18, 2010, 7:15pm UTC](https://www.ruby-forum.com/t/rails-3-new-namespace-inside-nested-resource/187152 "2010-04-18T19:15:19Z")

</div>

Hi, Is there a way to use namespaces inside nested resources? For example, I have: resources :users do resources :tags end and I’d like to place the tags controller inside controllers/users, with the equivalent fo…

---

## [Is there a way to use @today in a model?](https://www.ruby-forum.com/t/is-there-a-way-to-use-today-in-a-model/187136)

<div class="topic-metadata">

**Author:** [@adistarmid](https://www.ruby-forum.com/u/adistarmid)\
**Replies:** 4\
**Last updated:** [April 18, 2010, 5:49pm UTC](https://www.ruby-forum.com/t/is-there-a-way-to-use-today-in-a-model/187136 "2010-04-18T17:49:52Z")

</div>

I’m trying to get records from a has\_many that are only from this year. has\_many :visit, :conditions =\> “year = #{@today.year}”, :dependent =\> :destroy This has trouble. it thinks @today is null… Any other ideas? Bo…

---

## [What is the best way to test subdomain routes in Rails3 development](https://www.ruby-forum.com/t/what-is-the-best-way-to-test-subdomain-routes-in-rails3-development/187148)

<div class="topic-metadata">

**Author:** [@builtbysimple](https://www.ruby-forum.com/u/builtbysimple)\
**Replies:** 0\
**Last updated:** [April 18, 2010, 3:34pm UTC](https://www.ruby-forum.com/t/what-is-the-best-way-to-test-subdomain-routes-in-rails3-development/187148 "2010-04-18T15:34:40Z")

</div>

Hi all, In Rails3 we can define a constraint for subdomain as such: constraints(:subdomain =\> “support”) do … end But if we are using development web server like webrick, how would we be able to test it? Anybody ha…

---

## [Getter and Setter with non DB property](https://www.ruby-forum.com/t/getter-and-setter-with-non-db-property/187143)

<div class="topic-metadata">

**Author:** [@gregm](https://www.ruby-forum.com/u/gregm)\
**Replies:** 1\
**Last updated:** [April 18, 2010, 2:55pm UTC](https://www.ruby-forum.com/t/getter-and-setter-with-non-db-property/187143 "2010-04-18T14:55:27Z")

</div>

Hi, I can’t find how do i created a getter and setter property for a non db property. what i have done isnt working, i have a cnt mass assign error. Here is what i’ve done: attr\_accessor :creator\_is\_participant def …

---

## [Nil.to\_sym Problem](https://www.ruby-forum.com/t/nil-to-sym-problem/187142)

<div class="topic-metadata">

**Author:** [@Guru\_101011](https://www.ruby-forum.com/u/Guru_101011)\
**Replies:** 1\
**Last updated:** [April 18, 2010, 11:44am UTC](https://www.ruby-forum.com/t/nil-to-sym-problem/187142 "2010-04-18T11:44:07Z")

</div>

HI everyone, require some help! cannot figure out this error and how to fix it! Showing user/index.html.erb where line #59 raised: You have a nil object when you didn’t expect it! The error occurred while evaluating …

---

## [Having trouble looping through an array of Regular Expressions in a Rake task](https://www.ruby-forum.com/t/having-trouble-looping-through-an-array-of-regular-expressions-in-a-rake-task/187131)

<div class="topic-metadata">

**Author:** [@command0](https://www.ruby-forum.com/u/command0)\
**Replies:** 1\
**Last updated:** [April 18, 2010, 11:30am UTC](https://www.ruby-forum.com/t/having-trouble-looping-through-an-array-of-regular-expressions-in-a-rake-task/187131 "2010-04-18T11:30:04Z")

</div>

Hey guys, I was wondering if someone could give me some insight on an issue I’m having. I am working on a Rails app that will be a data efficient, user friendly New King James Version of the Bible. What I am presentl…

---

## [Something about Homebrew install ruby](https://www.ruby-forum.com/t/something-about-homebrew-install-ruby/187141)

<div class="topic-metadata">

**Author:** [@yang\_zaac](https://www.ruby-forum.com/u/yang_zaac)\
**Replies:** 0\
**Last updated:** [April 18, 2010, 11:24am UTC](https://www.ruby-forum.com/t/something-about-homebrew-install-ruby/187141 "2010-04-18T11:24:47Z")

</div>

I installed the ruby1.8.7 by macports. Yesterday, I updated the ruby into 1.9.1 by homebrew. But when I show the version (ruby -v),It still is 1.8.7. So I use brew link ruby,and replace the /opt/local/bin/ruby by /u…

---

## [Getting a duplicate record with has\_many and update\_attributes](https://www.ruby-forum.com/t/getting-a-duplicate-record-with-has-many-and-update-attributes/226064)

<div class="topic-metadata">

**Author:** [@adistarmid](https://www.ruby-forum.com/u/adistarmid)\
**Replies:** 3\
**Last updated:** [April 18, 2010, 7:38am UTC](https://www.ruby-forum.com/t/getting-a-duplicate-record-with-has-many-and-update-attributes/226064 "2010-04-18T07:38:51Z")

</div>

Please help. I’ve tried all i know with no results… I have an app with a master class using has\_many to another class. When I create a new record with the params showing all fields for master and the has\_many class it…

---

## [Rails custom helpers](https://www.ruby-forum.com/t/rails-custom-helpers/187127)

<div class="topic-metadata">

**Author:** [@bigdaddy71](https://www.ruby-forum.com/u/bigdaddy71)\
**Replies:** 4\
**Last updated:** [April 18, 2010, 4:29am UTC](https://www.ruby-forum.com/t/rails-custom-helpers/187127 "2010-04-18T04:29:15Z")

</div>

I made a helper module and put it in the helper directory but when I try and access any methods it says it does not recognize them. Ideas? Rails 2.3.5 Helper: module XmlTestDataHelper def update\_xml\_data end end C…

---

## [Contet\_tag :ul question](https://www.ruby-forum.com/t/contet-tag-ul-question/187098)

<div class="topic-metadata">

**Author:** [@pitosalas](https://www.ruby-forum.com/u/pitosalas)\
**Replies:** 3\
**Last updated:** [April 18, 2010, 12:08am UTC](https://www.ruby-forum.com/t/contet-tag-ul-question/187098 "2010-04-18T00:08:16Z")

</div>

Hi all This isn’t doing what I expect it to. Can you give it a quick look-see if you have a moment? def user\_navigation\_helper content\_tag(:div, :class =\>“banner\_right”) do content\_tag(:ul, :class =\> “wat-cf”) do i…

---

## [Validates\_format\_of with condition](https://www.ruby-forum.com/t/validates-format-of-with-condition/187077)

<div class="topic-metadata">

**Author:** [@gandhi-tush](https://www.ruby-forum.com/u/gandhi-tush)\
**Replies:** 4\
**Last updated:** [April 17, 2010, 8:14pm UTC](https://www.ruby-forum.com/t/validates-format-of-with-condition/187077 "2010-04-17T20:14:11Z")

</div>

Hi, I am trying to validate the email format by using “validates\_format\_of”. I have written a code like this:- "validates\_format\_of :email, :with=\>/^\[0-9a-zA-Z\_\]\[\\w.-\]\[a-zA-Z0-9\_\]@\[a-zA-Z0-9\]\[\\w.-\]\[a-zA-Z0-9\].\[a-zA-Z…

---

## [Design - Best practices on managing many-to-many controllers?](https://www.ruby-forum.com/t/design-best-practices-on-managing-many-to-many-controllers/187121)

<div class="topic-metadata">

**Author:** [@anr](https://www.ruby-forum.com/u/anr)\
**Replies:** 1\
**Last updated:** [April 17, 2010, 6:56pm UTC](https://www.ruby-forum.com/t/design-best-practices-on-managing-many-to-many-controllers/187121 "2010-04-17T18:56:21Z")

</div>

Hi, This may seem a silly question, but I didn’t find an elegant solution to manage a user’s tag collection. Perhaps I’m missing something, I’d like to know if there is a better way to handle it are. The configuratio…

---

## [Controller request.body?](https://www.ruby-forum.com/t/controller-request-body/187103)

<div class="topic-metadata">

**Author:** [@bigdaddy71](https://www.ruby-forum.com/u/bigdaddy71)\
**Replies:** 5\
**Last updated:** [April 17, 2010, 6:28pm UTC](https://www.ruby-forum.com/t/controller-request-body/187103 "2010-04-17T18:28:51Z")

</div>

I am trying to get the body of the request coming in to the controller. request.body is a StringIO object. I cannot seem to see what is actually inside it. any ideas?

---

## [Allow '.' to be a part of identifier, not a separator of format](https://www.ruby-forum.com/t/allow-to-be-a-part-of-identifier-not-a-separator-of-format/187053)

<div class="topic-metadata">

**Author:** [@makoto\_kuwata](https://www.ruby-forum.com/u/makoto_kuwata)\
**Replies:** 1\
**Last updated:** [April 17, 2010, 5:17pm UTC](https://www.ruby-forum.com/t/allow-to-be-a-part-of-identifier-not-a-separator-of-format/187053 "2010-04-17T17:17:27Z")

</div>

Hi, I have a question about available characters for url in Rails3. Is it possible to include ‘.’ as identifier of resources? Background I want to use title name as identifier instead of id in url path, for example: …

---

## [Newb's quick question on session variable vs. params in 'pretty' urls](https://www.ruby-forum.com/t/newbs-quick-question-on-session-variable-vs-params-in-pretty-urls/187029)

<div class="topic-metadata">

**Author:** [@grar](https://www.ruby-forum.com/u/grar)\
**Replies:** 3\
**Last updated:** [April 17, 2010, 4:17pm UTC](https://www.ruby-forum.com/t/newbs-quick-question-on-session-variable-vs-params-in-pretty-urls/187029 "2010-04-17T16:17:09Z")

</div>

Hi, Is there a compelling reason to prefer reliance on the params hash vs. the same info stored in a session hash? So, for example, params\[:id\] = @loan vs. session\[:loan\_id\] = @loan.id? It matters because I can make …

---

## [\[Ajax and RJS\] :bottom is null](https://www.ruby-forum.com/t/ajax-and-rjs-bottom-is-null/187118)

<div class="topic-metadata">

**Author:** [@gregm](https://www.ruby-forum.com/u/gregm)\
**Replies:** 0\
**Last updated:** [April 17, 2010, 2:38pm UTC](https://www.ruby-forum.com/t/ajax-and-rjs-bottom-is-null/187118 "2010-04-17T14:38:52Z")

</div>

Hello, I ma following ryanb screencast about Ajax, and i am trying to add an element to my list using ajax and RJS. My problem is that my object is correctly inserted but the rendering isn’t working because the “botto…

---

## [Where can i find video turorials of Ruby on Rails](https://www.ruby-forum.com/t/where-can-i-find-video-turorials-of-ruby-on-rails/130872)

<div class="topic-metadata">

**Author:** [@bijujoseph](https://www.ruby-forum.com/u/bijujoseph)\
**Replies:** 9\
**Last updated:** [April 17, 2010, 1:50pm UTC](https://www.ruby-forum.com/t/where-can-i-find-video-turorials-of-ruby-on-rails/130872 "2010-04-17T13:50:51Z")

</div>

Hi all, I am new to Ruby on Rails… I have read about its simple and great features. I really want to study Ruby on Rails… I really enjoy studying a new technology by watching the video tutorials of that. Can i anyb…

---

## [Question: How do I mix Ruby and Javascript in application.js](https://www.ruby-forum.com/t/question-how-do-i-mix-ruby-and-javascript-in-application-js/187102)

<div class="topic-metadata">

**Author:** [@jose](https://www.ruby-forum.com/u/jose)\
**Replies:** 1\
**Last updated:** [April 17, 2010, 1:46pm UTC](https://www.ruby-forum.com/t/question-how-do-i-mix-ruby-and-javascript-in-application-js/187102 "2010-04-17T13:46:10Z")

</div>

How can I get rails to process and serve application.js.erb instead of application.js? I want to mix Ruby and Javascript code in the file. I am building Javascript arrays from data that i keep in a Rails model and th…

---

## [About HTTP-only cookies in Ruby on rails](https://www.ruby-forum.com/t/about-http-only-cookies-in-ruby-on-rails/187116)

<div class="topic-metadata">

**Author:** [@Yuchen\_Z](https://www.ruby-forum.com/u/Yuchen_Z)\
**Replies:** 1\
**Last updated:** [April 17, 2010, 1:42pm UTC](https://www.ruby-forum.com/t/about-http-only-cookies-in-ruby-on-rails/187116 "2010-04-17T13:42:39Z")

</div>

Hi all, I am a security researcher at University of Virginia, I am currently doing research on HTTP-only cookie deployment. May I ask do ruby on rails support HTTP-only cookies, if yes, what is the default configurat…

---

## [A very weird bug in ruby](https://www.ruby-forum.com/t/a-very-weird-bug-in-ruby/187113)

<div class="topic-metadata">

**Author:** [@Trausti\_Thor\_J](https://www.ruby-forum.com/u/Trausti_Thor_J)\
**Replies:** 2\
**Last updated:** [April 17, 2010, 12:57pm UTC](https://www.ruby-forum.com/t/a-very-weird-bug-in-ruby/187113 "2010-04-17T12:57:01Z")

</div>

Yes yes, I think I have found my 2nd compiler bug (not counting realbasic). I think I found an actual bug in Ruby, on all platforms none the less (well linux and mac). if yu just run console or irb and do this ph = …

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

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