# Rails

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

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

---

## [Detect flash enabled](https://www.ruby-forum.com/t/detect-flash-enabled/160436)

<div class="topic-metadata">

**Author:** [@BelSSSSn](https://www.ruby-forum.com/u/BelSSSSn)\
**Replies:** 1\
**Last updated:** [February 16, 2009, 12:56pm UTC](https://www.ruby-forum.com/t/detect-flash-enabled/160436 "2009-02-16T12:56:13Z")

</div>

I am newbie at RoR, I want to detect if a browser has enabled flash player and if not show an static image. How can I do that?? Thanks in advance, Belén Llamas

---

## [How best to share code between apps?](https://www.ruby-forum.com/t/how-best-to-share-code-between-apps/160409)

<div class="topic-metadata">

**Author:** [@snowbird122](https://www.ruby-forum.com/u/snowbird122)\
**Replies:** 6\
**Last updated:** [February 16, 2009, 12:31pm UTC](https://www.ruby-forum.com/t/how-best-to-share-code-between-apps/160409 "2009-02-16T12:31:34Z")

</div>

I come from a PHP environment where we have a “library” of sorts that contains various functionality in the form of object-oriented classes. The classes can be tied into any new project and the functionality of that …

---

## [Working with Blocks](https://www.ruby-forum.com/t/working-with-blocks/160426)

<div class="topic-metadata">

**Author:** [@casper\_the\_ghost](https://www.ruby-forum.com/u/casper_the_ghost)\
**Replies:** 2\
**Last updated:** [February 16, 2009, 12:15pm UTC](https://www.ruby-forum.com/t/working-with-blocks/160426 "2009-02-16T12:15:01Z")

</div>

hey I am able to do: block\_func(x, y) do .... end But if I try to do this: form.block\_func(x, y) do .... end I get an error like this: syntax error, unexpected ')' @output\_buffer.concat " "; @output\_…

---

## [Format.atom renders builder templates inside HTML application layout in 2.3.0](https://www.ruby-forum.com/t/format-atom-renders-builder-templates-inside-html-application-layout-in-2-3-0/160355)

<div class="topic-metadata">

**Author:** [@Wincent\_C](https://www.ruby-forum.com/u/Wincent_C)\
**Replies:** 1\
**Last updated:** [February 16, 2009, 12:09pm UTC](https://www.ruby-forum.com/t/format-atom-renders-builder-templates-inside-html-application-layout-in-2-3-0/160355 "2009-02-16T12:09:07Z")

</div>

Given a builder template at “app/views/posts/index.atom.builder”, in 2.2.2 my controller methods could render atom feeds like this: format.atom { @posts = Post.find(:all) } As of 2.3.0 RC1, that code produces unusable…

---

## [Will\_paginate](https://www.ruby-forum.com/t/will-paginate/160432)

<div class="topic-metadata">

**Author:** [@fRAnKEnSTEin](https://www.ruby-forum.com/u/fRAnKEnSTEin)\
**Replies:** 0\
**Last updated:** [February 16, 2009, 11:15am UTC](https://www.ruby-forum.com/t/will-paginate/160432 "2009-02-16T11:15:01Z")

</div>

Hi there, I am paginating my products using “will\_paginate”(12 items per page), and i added this line to my routes file, for make “wil\_paginate” work with friendly url’s: map.paginated\_product ‘products/page/:page’, …

---

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

<div class="topic-metadata">

**Author:** [@fRAnKEnSTEin](https://www.ruby-forum.com/u/fRAnKEnSTEin)\
**Replies:** 1\
**Last updated:** [February 16, 2009, 9:59am UTC](https://www.ruby-forum.com/t/routes/160428 "2009-02-16T09:59:08Z")

</div>

Hi there, I have a photo gallery wich i paginate with “will\_paginate”. I added this line to my routes file, to make “will\_paginate” work with friendly url’s: map.paginated\_gallery ‘gallery/page/:page’, :controller =\> …

---

## [Uploading Image File via API?](https://www.ruby-forum.com/t/uploading-image-file-via-api/160424)

<div class="topic-metadata">

**Author:** [@Arie\_Kusuma\_A](https://www.ruby-forum.com/u/Arie_Kusuma_A)\
**Replies:** 0\
**Last updated:** [February 16, 2009, 8:29am UTC](https://www.ruby-forum.com/t/uploading-image-file-via-api/160424 "2009-02-16T08:29:26Z")

</div>

Quick Question, Is it possible to upload image file via Rails API ? This is the scenario, our ruby on rails app’s API got accessed by PHP app, this PHP app inserts new data, but I’m wondering if Rails API can provide…

---

## [Tagging Articles with Models](https://www.ruby-forum.com/t/tagging-articles-with-models/160423)

<div class="topic-metadata">

**Author:** [@shane](https://www.ruby-forum.com/u/shane)\
**Replies:** 0\
**Last updated:** [February 16, 2009, 8:29am UTC](https://www.ruby-forum.com/t/tagging-articles-with-models/160423 "2009-02-16T08:29:25Z")

</div>

I’m new to Rails and I’m wondering how others would handle this. I want to be able to post articles and tag them with related teams and players. I want to avoid duplicating data by maintaining a list of tags and then …

---

## [What is the difference between build and new](https://www.ruby-forum.com/t/what-is-the-difference-between-build-and-new/160337)

<div class="topic-metadata">

**Author:** [@captaffy](https://www.ruby-forum.com/u/captaffy)\
**Replies:** 7\
**Last updated:** [February 16, 2009, 7:10am UTC](https://www.ruby-forum.com/t/what-is-the-difference-between-build-and-new/160337 "2009-02-16T07:10:26Z")

</div>

I use new in almost all my controllers, but sometimes I have seen the build method inside the controllers of some apps. Can someone explain when should I use build?

---

## [Hook Exist in Rails for System-Wide Exception Logging?](https://www.ruby-forum.com/t/hook-exist-in-rails-for-system-wide-exception-logging/160323)

<div class="topic-metadata">

**Author:** [@mrpete](https://www.ruby-forum.com/u/mrpete)\
**Replies:** 2\
**Last updated:** [February 16, 2009, 6:42am UTC](https://www.ruby-forum.com/t/hook-exist-in-rails-for-system-wide-exception-logging/160323 "2009-02-16T06:42:22Z")

</div>

On our production servers, I’d like all exceptions to be automatically logged to the database. In other C# project I wrote that meant putting a try/catch in every entry point method with the catch calling a generic ro…

---

## [How can I save the destination url with all the parameters?](https://www.ruby-forum.com/t/how-can-i-save-the-destination-url-with-all-the-parameters/160383)

<div class="topic-metadata">

**Author:** [@captaffy](https://www.ruby-forum.com/u/captaffy)\
**Replies:** 1\
**Last updated:** [February 16, 2009, 5:51am UTC](https://www.ruby-forum.com/t/how-can-i-save-the-destination-url-with-all-the-parameters/160383 "2009-02-16T05:51:31Z")

</div>

I want too save the destination url with all the parameters (like some ids) in a variable session, so first I login the app and then redirect to this destination. How can I save this variable?

---

## [Referencing a non-ActiveRecord attribute](https://www.ruby-forum.com/t/referencing-a-non-activerecord-attribute/160404)

<div class="topic-metadata">

**Author:** [@rapdup](https://www.ruby-forum.com/u/rapdup)\
**Replies:** 5\
**Last updated:** [February 16, 2009, 5:39am UTC](https://www.ruby-forum.com/t/referencing-a-non-activerecord-attribute/160404 "2009-02-16T05:39:50Z")

</div>

I am trying to access a model’s attribute that does not have a column in the model’s corresponding table. It exists only through an attr\_accessor: class Widget \< ActiveRecord::Base attr\_accessor :attribute\_not\_in\_db …

---

## [\[ANN\] Merb Mind Maps - a tutorial on RSpec, GraphViz & a little Merb](https://www.ruby-forum.com/t/ann-merb-mind-maps-a-tutorial-on-rspec-graphviz-a-little-merb/160411)

<div class="topic-metadata">

**Author:** [@Phlip](https://www.ruby-forum.com/u/Phlip)\
**Replies:** 0\
**Last updated:** [February 16, 2009, 4:05am UTC](https://www.ruby-forum.com/t/ann-merb-mind-maps-a-tutorial-on-rspec-graphviz-a-little-merb/160411 "2009-02-16T04:05:07Z")

</div>

Netizens: Crispin & Gregory’s new book, /Agile Testing: A Practical Guide for Testers and Agile Teams/, has a kewt “mind map” at the start of each chapter. It inspired me to find a way to use the “tag cloud” on a bl…

---

## [Two-to-one mappings](https://www.ruby-forum.com/t/two-to-one-mappings/160345)

<div class="topic-metadata">

**Author:** [@gregthegerg](https://www.ruby-forum.com/u/gregthegerg)\
**Replies:** 10\
**Last updated:** [February 16, 2009, 3:29am UTC](https://www.ruby-forum.com/t/two-to-one-mappings/160345 "2009-02-16T03:29:57Z")

</div>

Hey all, I have a pretty simple question, but I’m not sure of a good solution to it. Essentially, I want to provide a two-to-one mapping of models. I’m working on an application for a contest, where every (unordered) …

---

## [About validate](https://www.ruby-forum.com/t/about-validate/160325)

<div class="topic-metadata">

**Author:** [@Mike75](https://www.ruby-forum.com/u/Mike75)\
**Replies:** 2\
**Last updated:** [February 16, 2009, 1:31am UTC](https://www.ruby-forum.com/t/about-validate/160325 "2009-02-16T01:31:51Z")

</div>

hello… I am new to Ruby on Rails… (2.2) I am currently following steps from the book “agile web delopment with Rails” building depot application. It says I need to edit “app/models/product.rb” file and add the follo…

---

## [USPS web services and Ruby/Rails](https://www.ruby-forum.com/t/usps-web-services-and-ruby-rails/160399)

<div class="topic-metadata">

**Author:** [@mhfs](https://www.ruby-forum.com/u/mhfs)\
**Replies:** 0\
**Last updated:** [February 15, 2009, 10:03pm UTC](https://www.ruby-forum.com/t/usps-web-services-and-ruby-rails/160399 "2009-02-15T22:03:47Z")

</div>

Hello list, I was wondering who here already had to work with USPS from within a Rails app to implement fullfilment. I was working with Fedex, implementing not only cost calculation but also the shipping request, voi…

---

## [Trying to Wrap My Head Around HM:t and HABTM w/ a Sample App](https://www.ruby-forum.com/t/trying-to-wrap-my-head-around-hm-t-and-habtm-w-a-sample-app/160200)

<div class="topic-metadata">

**Author:** [@spammy](https://www.ruby-forum.com/u/spammy)\
**Replies:** 6\
**Last updated:** [February 15, 2009, 10:02pm UTC](https://www.ruby-forum.com/t/trying-to-wrap-my-head-around-hm-t-and-habtm-w-a-sample-app/160200 "2009-02-15T22:02:48Z")

</div>

I am cheap and in an attempt to learn about rails & relationships I’m trying to create an application that my friends and I can use as a way to split the cost of items we buy @ Costco. Right now the models i have are: …

---

## [How to get the value of Collection\_select in controller](https://www.ruby-forum.com/t/how-to-get-the-value-of-collection-select-in-controller/160372)

<div class="topic-metadata">

**Author:** [@hamidraza](https://www.ruby-forum.com/u/hamidraza)\
**Replies:** 2\
**Last updated:** [February 15, 2009, 10:01pm UTC](https://www.ruby-forum.com/t/how-to-get-the-value-of-collection-select-in-controller/160372 "2009-02-15T22:01:33Z")

</div>

this is my view code \<%= f.collection\_select(:user, :province\_id , @provinces ,:id , :name) %\> and this is my controller code params\[:user\_province\_id\] it is giving nothing :frowning: when i use observe field and …

---

## [I get â€œMissing these required gemsâ€, but gems are installed](https://www.ruby-forum.com/t/i-get-a-oemissing-these-required-gemsa-but-gems-are-installed/160338)

<div class="topic-metadata">

**Author:** [@collimarco](https://www.ruby-forum.com/u/collimarco)\
**Replies:** 3\
**Last updated:** [February 15, 2009, 8:32pm UTC](https://www.ruby-forum.com/t/i-get-a-oemissing-these-required-gemsa-but-gems-are-installed/160338 "2009-02-15T20:32:14Z")

</div>

Hi, since I updated ruby using Mac Ports (on Leopard) I have got several problems and I also had to reinstall gems. Now when I run Mongrel I keep getting the error “Missing these required gems” followed by the list of …

---

## [ActionController::Caching::Sweeper not autoloading in 2.3.0 RC1](https://www.ruby-forum.com/t/actioncontroller-sweeper-not-autoloading-in-2-3-0-rc1/159449)

<div class="topic-metadata">

**Author:** [@Wincent\_C](https://www.ruby-forum.com/u/Wincent_C)\
**Replies:** 1\
**Last updated:** [February 15, 2009, 7:48pm UTC](https://www.ruby-forum.com/t/actioncontroller-sweeper-not-autoloading-in-2-3-0-rc1/159449 "2009-02-15T19:48:00Z")

</div>

Just updated to 2.3.0 RC1 and I’m finding that my sweepers are throwing NameErrors (uninitialized constant ActionController::Caching::Sweeper) when evaluation reaches lines like this one: class PostSweeper \< ActionCo…

---

## [404 error after deploying an app with passenger](https://www.ruby-forum.com/t/404-error-after-deploying-an-app-with-passenger/160366)

<div class="topic-metadata">

**Author:** [@landry](https://www.ruby-forum.com/u/landry)\
**Replies:** 1\
**Last updated:** [February 15, 2009, 5:41pm UTC](https://www.ruby-forum.com/t/404-error-after-deploying-an-app-with-passenger/160366 "2009-02-15T17:41:35Z")

</div>

Hello, I’m desperatly trying to install an app with phusion passenger. I’ve already spent 2 days with no success, can somebody help me, please ? Here is my problem : I already installed phusion passenger with no prob…

---

## [Trying the ol' articles route, need some help](https://www.ruby-forum.com/t/trying-the-ol-articles-route-need-some-help/160348)

<div class="topic-metadata">

**Author:** [@yaphi](https://www.ruby-forum.com/u/yaphi)\
**Replies:** 2\
**Last updated:** [February 15, 2009, 5:18pm UTC](https://www.ruby-forum.com/t/trying-the-ol-articles-route-need-some-help/160348 "2009-02-15T17:18:04Z")

</div>

Hey there, I am trying to figure out routing and thought that this would probably be the best way to learn how to do some complicated routes. I’ve looked at a lot of people’s methods for getting the /articles/ 2009/0…

---

## [Redirect\_to Vs Render\_component](https://www.ruby-forum.com/t/redirect-to-vs-render-component/160256)

<div class="topic-metadata">

**Author:** [@srividya\_sharma](https://www.ruby-forum.com/u/srividya_sharma)\
**Replies:** 7\
**Last updated:** [February 15, 2009, 5:15pm UTC](https://www.ruby-forum.com/t/redirect-to-vs-render-component/160256 "2009-02-15T17:15:26Z")

</div>

Hello I am using Rails 2.2.2. Here is my problem: I have a controller action which will receive several parameters, validate them, process them and create a new set of parameters out of them. Then, this controller …

---

## [Collapsible Fieldset](https://www.ruby-forum.com/t/collapsible-fieldset/160376)

<div class="topic-metadata">

**Author:** [@juli](https://www.ruby-forum.com/u/juli)\
**Replies:** 2\
**Last updated:** [February 15, 2009, 4:13pm UTC](https://www.ruby-forum.com/t/collapsible-fieldset/160376 "2009-02-15T16:13:33Z")

</div>

Hey there, (First steps in Ruby and Rails…) I’m trying to make a fieldset collapsible, like they are, for example, on many Drupal pages. What I’ve figuared out is the following: \<%= link\_to\_function("Show/Hi…

---

## [Schedule job in rails](https://www.ruby-forum.com/t/schedule-job-in-rails/160218)

<div class="topic-metadata">

**Author:** [@on9west](https://www.ruby-forum.com/u/on9west)\
**Replies:** 16\
**Last updated:** [February 15, 2009, 3:10pm UTC](https://www.ruby-forum.com/t/schedule-job-in-rails/160218 "2009-02-15T15:10:08Z")

</div>

Dear all I created a module in my\_rails\_project/lib/ssc.rb. I can execute the method in rails console (i.e. SSC::Monitor.method1(a,b)). How can I execute the method regularly? I am using Linux, can I do it using cron…

---

## [Reset password facility](https://www.ruby-forum.com/t/reset-password-facility/160115)

<div class="topic-metadata">

**Author:** [@Shockmeister](https://www.ruby-forum.com/u/Shockmeister)\
**Replies:** 3\
**Last updated:** [February 15, 2009, 2:47pm UTC](https://www.ruby-forum.com/t/reset-password-facility/160115 "2009-02-15T14:47:14Z")

</div>

I have used a sha256 hashing algorithm in order to provide some security to my login facility. I now want to create a facility whereby, if the user forgets their password, they are emailed a temporary password so that…

---

## [RESTful authentication plugin information](https://www.ruby-forum.com/t/restful-authentication-plugin-information/160365)

<div class="topic-metadata">

**Author:** [@sag](https://www.ruby-forum.com/u/sag)\
**Replies:** 0\
**Last updated:** [February 15, 2009, 1:34pm UTC](https://www.ruby-forum.com/t/restful-authentication-plugin-information/160365 "2009-02-15T13:34:30Z")

</div>

hi i want to having how restful rails working.How it will used to create views? what are procs n concs of this tool? should i prefer for web mashup or not?

---

## [Serialize ... what am I doing wrong?](https://www.ruby-forum.com/t/serialize-what-am-i-doing-wrong/160331)

<div class="topic-metadata">

**Author:** [@philswenson](https://www.ruby-forum.com/u/philswenson)\
**Replies:** 4\
**Last updated:** [February 15, 2009, 11:56am UTC](https://www.ruby-forum.com/t/serialize-what-am-i-doing-wrong/160331 "2009-02-15T11:56:21Z")

</div>

Hi. I want to serialize out an object to the database. But I am getting an integer value in the column when I expect to see some yaml! migration: class CreateSummaries \< ActiveRecord::Migration def self.up create\_t…

---

## ["reaper" is not picking up new changes to my application?](https://www.ruby-forum.com/t/reaper-is-not-picking-up-new-changes-to-my-application/159831)

<div class="topic-metadata">

**Author:** [@greg](https://www.ruby-forum.com/u/greg)\
**Replies:** 5\
**Last updated:** [February 15, 2009, 11:27am UTC](https://www.ruby-forum.com/t/reaper-is-not-picking-up-new-changes-to-my-application/159831 "2009-02-15T11:27:37Z")

</div>

Hi, Can anyone shed any light on why “reaper” (whilst seemingly working re restarting my mongrel ruby process) does not pick up changes to my application? (e.g. changing a title in a view for example). It’s like t…

---

## [Undefined method 'parameters' on controller.request](https://www.ruby-forum.com/t/undefined-method-parameters-on-controller-request/160320)

<div class="topic-metadata">

**Author:** [@Michael\_JSISJacks](https://www.ruby-forum.com/u/Michael_JSISJacks)\
**Replies:** 2\
**Last updated:** [February 15, 2009, 7:06am UTC](https://www.ruby-forum.com/t/undefined-method-parameters-on-controller-request/160320 "2009-02-15T07:06:36Z")

</div>

I’m getting a NoMethodError using Rails 2.1.0 when trying to send an email using ActionMailer. The error is being thrown from the template\_format method in ActionView’s base.rb file. Apparently the controller.request …

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

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