# Rails

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

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

---

## [\[brazilian\_rails\] formatando datas antes de enviar ao banco](https://www.ruby-forum.com/t/brazilian-rails-formatando-datas-antes-de-enviar-ao-banco/137727)

<div class="topic-metadata">

**Author:** [@flaubert](https://www.ruby-forum.com/u/flaubert)\
**Replies:** 1\
**Last updated:** [May 16, 2008, 1:33pm UTC](https://www.ruby-forum.com/t/brazilian-rails-formatando-datas-antes-de-enviar-ao-banco/137727 "2008-05-16T13:33:22Z")

</div>

Olah pessoal do brasil, bem quem usa o plugin brazilian rails ja deve ter passado por isso, eu me INVENTEI de usa-lo ha uns dias, estou adorando. Porém me vi num problema que resolvi (de uma maneira incrivelmente FE…

---

## [Saving xml file to mysql database using ruby on rails](https://www.ruby-forum.com/t/saving-xml-file-to-mysql-database-using-ruby-on-rails/137767)

<div class="topic-metadata">

**Author:** [@hloooi](https://www.ruby-forum.com/u/hloooi)\
**Replies:** 5\
**Last updated:** [May 16, 2008, 12:23pm UTC](https://www.ruby-forum.com/t/saving-xml-file-to-mysql-database-using-ruby-on-rails/137767 "2008-05-16T12:23:08Z")

</div>

hi, can anyone help me with this problem : saving xml file to mysql database using ruby on rails, then read the value/parameters from the xml file, thx~~~

---

## [Send a file, is it possible to do something like this?](https://www.ruby-forum.com/t/send-a-file-is-it-possible-to-do-something-like-this/137692)

<div class="topic-metadata">

**Author:** [@xdmx](https://www.ruby-forum.com/u/xdmx)\
**Replies:** 5\
**Last updated:** [May 16, 2008, 12:19pm UTC](https://www.ruby-forum.com/t/send-a-file-is-it-possible-to-do-something-like-this/137692 "2008-05-16T12:19:35Z")

</div>

Hi, i’ve servers (not connected directly, only by internet), one with a rails app, and another with the big static files. The problem is, to access to one of them file you have to be logged, and when you click on a li…

---

## [Server Specs for deployment](https://www.ruby-forum.com/t/server-specs-for-deployment/137646)

<div class="topic-metadata">

**Author:** [@bigdaddy71](https://www.ruby-forum.com/u/bigdaddy71)\
**Replies:** 3\
**Last updated:** [May 16, 2008, 12:17pm UTC](https://www.ruby-forum.com/t/server-specs-for-deployment/137646 "2008-05-16T12:17:13Z")

</div>

The rails app I have created is an online assessment for 3rd - 5th graders. When the project goes into production there will be 300-400 kids accessing the site at the same time. I have been speeking with several hos…

---

## [Address Book Import](https://www.ruby-forum.com/t/address-book-import/113275)

<div class="topic-metadata">

**Author:** [@pradeep](https://www.ruby-forum.com/u/pradeep)\
**Replies:** 2\
**Last updated:** [May 16, 2008, 11:30am UTC](https://www.ruby-forum.com/t/address-book-import/113275 "2008-05-16T11:30:01Z")

</div>

Hi All, Is there any way to import address book of rediffmail and indiatimes using ruby. Please let me know the details. Thanks in Advance Regards, Pradeep

---

## [Template structure oke?](https://www.ruby-forum.com/t/template-structure-oke/137783)

<div class="topic-metadata">

**Author:** [@remco123](https://www.ruby-forum.com/u/remco123)\
**Replies:** 0\
**Last updated:** [May 16, 2008, 10:25am UTC](https://www.ruby-forum.com/t/template-structure-oke/137783 "2008-05-16T10:25:50Z")

</div>

Hi, In my layout/application.rhtml there is a form for finding/cheching airline-tickets online. The value in the form is filled in based on the destination.name \<% form\_for @destination do |f| %\> \<%= f.text\_field :n…

---

## [Combine RESTful routes with DataMapper](https://www.ruby-forum.com/t/combine-restful-routes-with-datamapper/137779)

<div class="topic-metadata">

**Author:** [@makire](https://www.ruby-forum.com/u/makire)\
**Replies:** 0\
**Last updated:** [May 16, 2008, 9:49am UTC](https://www.ruby-forum.com/t/combine-restful-routes-with-datamapper/137779 "2008-05-16T09:49:47Z")

</div>

Hi I am writing an app in Rails 2 using DataMapper as ORM. It works fine but an unexpected downside is that generated RESTful routes does not work. In Rails 2 you can for example write: edit\_product\_path(product) an…

---

## [Sql queries in rails](https://www.ruby-forum.com/t/sql-queries-in-rails/137773)

<div class="topic-metadata">

**Author:** [@casper\_the\_ghost](https://www.ruby-forum.com/u/casper_the_ghost)\
**Replies:** 1\
**Last updated:** [May 16, 2008, 8:56am UTC](https://www.ruby-forum.com/t/sql-queries-in-rails/137773 "2008-05-16T08:56:18Z")

</div>

I have an assignment and I need to be able to run a query inputted by the user (no matter what the query). Also I need to display the result cleanly with the field names if the query was a select query. So far I have …

---

## [Problem with :action =\> 'destroy' in url\_for](https://www.ruby-forum.com/t/problem-with-action-destroy-in-url-for/137776)

<div class="topic-metadata">

**Author:** [@vmoroz](https://www.ruby-forum.com/u/vmoroz)\
**Replies:** 0\
**Last updated:** [May 16, 2008, 8:54am UTC](https://www.ruby-forum.com/t/problem-with-action-destroy-in-url-for/137776 "2008-05-16T08:54:31Z")

</div>

url\_for( :controller =\> ‘foo’, :action =\> ‘destroy’, :id =\> 1 ) =\> ‘/ foo/1’ url\_for( :controller =\> ‘foo’, :action =\> ‘destroy\_x’, :id =\> 1 ) =\> '/ foo/destroy\_x/1 url\_for( :controller =\> ‘foo’, :action =\> ‘destroy’…

---

## [Select \* from users where id in (2,5,8)](https://www.ruby-forum.com/t/select-from-users-where-id-in-2-5-8/137486)

<div class="topic-metadata">

**Author:** [@david](https://www.ruby-forum.com/u/david)\
**Replies:** 2\
**Last updated:** [May 16, 2008, 8:19am UTC](https://www.ruby-forum.com/t/select-from-users-where-id-in-2-5-8/137486 "2008-05-16T08:19:48Z")

</div>

Hello, I’m trying to search for users in a set of ids: select \* from users where id in (2,5,8) Is there a “RoR” way to do the above query without having to resort to find\_by\_sql? Or are there any plugins that allow …

---

## [\[ANN\] Semantic Attributes (validation, machine/human formatting)](https://www.ruby-forum.com/t/ann-semantic-attributes-validation-machine-human-formatting/137770)

<div class="topic-metadata">

**Author:** [@cainlevy](https://www.ruby-forum.com/u/cainlevy)\
**Replies:** 0\
**Last updated:** [May 16, 2008, 6:13am UTC](https://www.ruby-forum.com/t/ann-semantic-attributes-validation-machine-human-formatting/137770 "2008-05-16T06:13:18Z")

</div>

I’ve never taken the time to package/release/announce this plugin of mine, have I? Forgive me. The time has come. I introduce to you Semantic Attributes! From the README: The method-chained validation routine built …

---

## [How to test mobile web app](https://www.ruby-forum.com/t/how-to-test-mobile-web-app/137743)

<div class="topic-metadata">

**Author:** [@dicouw](https://www.ruby-forum.com/u/dicouw)\
**Replies:** 2\
**Last updated:** [May 16, 2008, 5:17am UTC](https://www.ruby-forum.com/t/how-to-test-mobile-web-app/137743 "2008-05-16T05:17:45Z")

</div>

Hello ! I’m working on a mobile version of my website, but I don’t really know how to test it, how to see if the layout is fine etc… Does anybody know how can I do to find a simulator or something like that? (for w…

---

## [Fleximage problem](https://www.ruby-forum.com/t/fleximage-problem/137764)

<div class="topic-metadata">

**Author:** [@joel](https://www.ruby-forum.com/u/joel)\
**Replies:** 0\
**Last updated:** [May 16, 2008, 3:08am UTC](https://www.ruby-forum.com/t/fleximage-problem/137764 "2008-05-16T03:08:08Z")

</div>

Hello, I’m using squeegy fleximage for image upload and rendering. My controller action code looks like this : def showimg @promo = Promotion.find(params\[:id\]) respond\_to do |format| #format.png { image\_tag @promo.…

---

## [Why are IE6 and Firefox rendering different formats from the same URL?](https://www.ruby-forum.com/t/why-are-ie6-and-firefox-rendering-different-formats-from-the-same-url/137663)

<div class="topic-metadata">

**Author:** [@HSWade\_M](https://www.ruby-forum.com/u/HSWade_M)\
**Replies:** 2\
**Last updated:** [May 16, 2008, 1:56am UTC](https://www.ruby-forum.com/t/why-are-ie6-and-firefox-rendering-different-formats-from-the-same-url/137663 "2008-05-16T01:56:46Z")

</div>

I have a controller action in my Rails 2.0.2 app that looks like this: def matrix @shows = Show.find(:all) @players = Player.find(:all) respond\_to do |format| format.html format.xls do set\_excel\_headers(headers,“m…

---

## [How to monkeypatch in a plugin](https://www.ruby-forum.com/t/how-to-monkeypatch-in-a-plugin/137755)

<div class="topic-metadata">

**Author:** [@kuma](https://www.ruby-forum.com/u/kuma)\
**Replies:** 1\
**Last updated:** [May 16, 2008, 12:41am UTC](https://www.ruby-forum.com/t/how-to-monkeypatch-in-a-plugin/137755 "2008-05-16T00:41:06Z")

</div>

Hi all, I’m working on a plugin that enables automatic profiling and benchmarking for unit tests. I need to monkeypatch Test::Unit::TestSuite to redefine the run method. Based on the example I see at http://svn.jth…

---

## [The 'rails' command is not working on Windows XP](https://www.ruby-forum.com/t/the-rails-command-is-not-working-on-windows-xp/137589)

<div class="topic-metadata">

**Author:** [@vikrant](https://www.ruby-forum.com/u/vikrant)\
**Replies:** 9\
**Last updated:** [May 15, 2008, 11:22pm UTC](https://www.ruby-forum.com/t/the-rails-command-is-not-working-on-windows-xp/137589 "2008-05-15T23:22:29Z")

</div>

After a recent restart of my PC, when I tried to execute “ruby script/ server”, it gave me an error, ‘ruby’ is not recognized as an internal or external command, operable program or batch file. I also tried commands …

---

## [New Fonts & PDF Writer](https://www.ruby-forum.com/t/new-fonts-pdf-writer/137746)

<div class="topic-metadata">

**Author:** [@unknown](https://www.ruby-forum.com/u/unknown)\
**Replies:** 0\
**Last updated:** [May 15, 2008, 10:53pm UTC](https://www.ruby-forum.com/t/new-fonts-pdf-writer/137746 "2008-05-15T22:53:39Z")

</div>

I’ve got PDF Writer installed and working. But for the PDF files that I want to generate, I need to use a non-standard font (Trade Gothic). I have the font installed on the system, but my RoR app never seems to find …

---

## [Model relationship design question](https://www.ruby-forum.com/t/model-relationship-design-question/137643)

<div class="topic-metadata">

**Author:** [@maestro777](https://www.ruby-forum.com/u/maestro777)\
**Replies:** 11\
**Last updated:** [May 15, 2008, 10:39pm UTC](https://www.ruby-forum.com/t/model-relationship-design-question/137643 "2008-05-15T22:39:57Z")

</div>

I have the following scenario. Three tables - Companies, Users and Submissions. Starting with Companies. Each company has many users. Each user can have one or more submissions (of articles related to a company). Henc…

---

## [Remove controller name from URL \> nested routes](https://www.ruby-forum.com/t/remove-controller-name-from-url-nested-routes/137679)

<div class="topic-metadata">

**Author:** [@remco123](https://www.ruby-forum.com/u/remco123)\
**Replies:** 1\
**Last updated:** [May 15, 2008, 9:43pm UTC](https://www.ruby-forum.com/t/remove-controller-name-from-url-nested-routes/137679 "2008-05-15T21:43:54Z")

</div>

Hi… There are my nested routes map.resources :continent do |continent| continent.resources :land do |land| land.resources :destination end end By example it generates this url http://example/continent/azie/land/j…

---

## [Issues with date\_select](https://www.ruby-forum.com/t/issues-with-date-select/137737)

<div class="topic-metadata">

**Author:** [@sgudibanda](https://www.ruby-forum.com/u/sgudibanda)\
**Replies:** 0\
**Last updated:** [May 15, 2008, 9:10pm UTC](https://www.ruby-forum.com/t/issues-with-date-select/137737 "2008-05-15T21:10:53Z")

</div>

Hi, I have an application where in I ask for DOB(date of birth) from users and i am using date\_select (discarding hour): If someone doesn’t enter day and month but enters YEAR(say 1980) in DOB - Its gets stored as …

---

## [Adding messages to a queue server from a model method](https://www.ruby-forum.com/t/adding-messages-to-a-queue-server-from-a-model-method/137735)

<div class="topic-metadata">

**Author:** [@Linicks](https://www.ruby-forum.com/u/Linicks)\
**Replies:** 0\
**Last updated:** [May 15, 2008, 8:59pm UTC](https://www.ruby-forum.com/t/adding-messages-to-a-queue-server-from-a-model-method/137735 "2008-05-15T20:59:50Z")

</div>

All, I’m trying to add/‘set’ values in the sparrow queue server (http:// Google Code Archive - Long-term storage for Google Code Project Hosting.) which is very similar to Starling. I can add values to the queue easi…

---

## [Why instance variable in destroy?](https://www.ruby-forum.com/t/why-instance-variable-in-destroy/137687)

<div class="topic-metadata">

**Author:** [@tuktuk](https://www.ruby-forum.com/u/tuktuk)\
**Replies:** 7\
**Last updated:** [May 15, 2008, 8:38pm UTC](https://www.ruby-forum.com/t/why-instance-variable-in-destroy/137687 "2008-05-15T20:38:29Z")

</div>

Ãn Rails 2.0 the scaffold generator (for e.g. a model called “Context”) creates the destroy method like this: def destroy @context = Context.find(params\[:id\]) @context.destroy respond\_to do |format| format.html {…

---

## [Partial\_updates feature in rails 2.1, failing to save because of validate\_presence \_of on other at](https://www.ruby-forum.com/t/partial-updates-feature-in-rails-2-1-failing-to-save-because-of-validate-presence-of-on-other-at/137733)

<div class="topic-metadata">

**Author:** [@Virginian](https://www.ruby-forum.com/u/Virginian)\
**Replies:** 0\
**Last updated:** [May 15, 2008, 8:23pm UTC](https://www.ruby-forum.com/t/partial-updates-feature-in-rails-2-1-failing-to-save-because-of-validate-presence-of-on-other-at/137733 "2008-05-15T20:23:47Z")

</div>

I am trying to use the new partial\_updates feature in rails 2.1, http://dev.rubyonrails.org/changeset/9157 but it is failing by trying to use all validations in the model instead of just the changed attributes. The m…

---

## [Hostname](https://www.ruby-forum.com/t/hostname/137180)

<div class="topic-metadata">

**Author:** [@nallamani](https://www.ruby-forum.com/u/nallamani)\
**Replies:** 3\
**Last updated:** [May 15, 2008, 8:05pm UTC](https://www.ruby-forum.com/t/hostname/137180 "2008-05-15T20:05:33Z")

</div>

Hi, I have written an rake task where I need to access “Hostname” . I need this feature because I will be testing my application using the rake task both locally and on live server . I found code in another language …

---

## [ActiveRecord - nil object when you didn't expect it](https://www.ruby-forum.com/t/activerecord-nil-object-when-you-didnt-expect-it/137673)

<div class="topic-metadata">

**Author:** [@deadinplastic](https://www.ruby-forum.com/u/deadinplastic)\
**Replies:** 4\
**Last updated:** [May 15, 2008, 7:49pm UTC](https://www.ruby-forum.com/t/activerecord-nil-object-when-you-didnt-expect-it/137673 "2008-05-15T19:49:37Z")

</div>

Hi, I have the following code in a RoR project, models and tests are all in the proper directories: require File.dirname(FILE) + ‘/…/test\_helper’ class GalleryTest \< Test::Unit::TestCase fixtures :galleries @galler…

---

## [ActionMailer Automatically sends an email everyday at a specific time](https://www.ruby-forum.com/t/actionmailer-automatically-sends-an-email-everyday-at-a-specific-time/137706)

<div class="topic-metadata">

**Author:** [@T\_K](https://www.ruby-forum.com/u/T_K)\
**Replies:** 1\
**Last updated:** [May 15, 2008, 7:31pm UTC](https://www.ruby-forum.com/t/actionmailer-automatically-sends-an-email-everyday-at-a-specific-time/137706 "2008-05-15T19:31:57Z")

</div>

Hi, I would like to have a notification system where an email is sent to specific addresses every morning with different contents everyday. The contents are stored in the data, but the number of recipients is a few. …

---

## [RoR, Django and Seam source code analysis](https://www.ruby-forum.com/t/ror-django-and-seam-source-code-analysis/137731)

<div class="topic-metadata">

**Author:** [@Alan\_Manian](https://www.ruby-forum.com/u/Alan_Manian)\
**Replies:** 0\
**Last updated:** [May 15, 2008, 7:26pm UTC](https://www.ruby-forum.com/t/ror-django-and-seam-source-code-analysis/137731 "2008-05-15T19:26:06Z")

</div>

Hi, In the great tradition of web framework comparisons :wink: : here is a blog entry focused on a source code analysis of RoR, Django and Seam: http://www.mininglabs.com/2008/05/13/web-frameworks-a-free-software-orie…

---

## [Display time in â€œUS-Centralâ€ Format Tzi nfo](https://www.ruby-forum.com/t/display-time-in-a-oeus-centrala-format-tzi-nfo/137728)

<div class="topic-metadata">

**Author:** [@nallamani](https://www.ruby-forum.com/u/nallamani)\
**Replies:** 0\
**Last updated:** [May 15, 2008, 7:17pm UTC](https://www.ruby-forum.com/t/display-time-in-a-oeus-centrala-format-tzi-nfo/137728 "2008-05-15T19:17:17Z")

</div>

Hi , Is there anyway I can display time in “US-Central” or “US-Eastern” format instead of “ America-New york” or “ Europe-Athens” format at the top of drop down list using Tzinfo . I am presently using “time\_zone\_sel…

---

## [Announcing Palmist: A Handy Tool for Finding and Fixing MySQL Bottlenecks in Rails](https://www.ruby-forum.com/t/announcing-palmist-a-handy-tool-for-finding-and-fixing-mysql-bottlenecks-in-rails/137726)

<div class="topic-metadata">

**Author:** [@casper\_the\_ghost](https://www.ruby-forum.com/u/casper_the_ghost)\
**Replies:** 1\
**Last updated:** [May 15, 2008, 7:09pm UTC](https://www.ruby-forum.com/t/announcing-palmist-a-handy-tool-for-finding-and-fixing-mysql-bottlenecks-in-rails/137726 "2008-05-15T19:09:00Z")

</div>

Palmist is a tool I’ve developed to make it easier to reduce the amount of time your rails app spends in a MySQL database. You can find out more about it here: http://www.flyingmachinestudios.com/2008/05/14/announcing…

---

## [Polls Plugin?](https://www.ruby-forum.com/t/polls-plugin/75426)

<div class="topic-metadata">

**Author:** [@saizai](https://www.ruby-forum.com/u/saizai)\
**Replies:** 1\
**Last updated:** [May 15, 2008, 7:06pm UTC](https://www.ruby-forum.com/t/polls-plugin/75426 "2008-05-15T19:06:02Z")

</div>

Just wondering if one exists already. Yeah it’s simple and I could code it myself but I’m a lazy bastard and would rather reuse someone else’s code. Ideally it’d be able to different question types - like LiveJournal’…

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

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