# Rails

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

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

---

## [CSV Download of any given model](https://www.ruby-forum.com/t/csv-download-of-any-given-model/106984)

<div class="topic-metadata">

**Author:** [@casper\_the\_ghost](https://www.ruby-forum.com/u/casper_the_ghost)\
**Replies:** 3\
**Last updated:** [July 29, 2007, 8:51pm UTC](https://www.ruby-forum.com/t/csv-download-of-any-given-model/106984 "2007-07-29T20:51:01Z")

</div>

I found sample code from the archives of this list to make CSV download of a model. It works fine. I am wondering if it is possible to generalize the code posted by François on his blog to handle any given model. cla…

---

## [A rather rudimentary & decidely dopey MySQL question](https://www.ruby-forum.com/t/a-rather-rudimentary-decidely-dopey-mysql-question/110692)

<div class="topic-metadata">

**Author:** [@casper\_the\_ghost](https://www.ruby-forum.com/u/casper_the_ghost)\
**Replies:** 1\
**Last updated:** [July 29, 2007, 7:19pm UTC](https://www.ruby-forum.com/t/a-rather-rudimentary-decidely-dopey-mysql-question/110692 "2007-07-29T19:19:47Z")

</div>

Email : removed\_email\_address@domain.invalid If I can do it then it can’t be done ! … - Anonymous Hi Everyone ! : I’m a Ruby on Rails noobie and a Unix ignoramus (not proud of it but there it is). I’m starting my 1…

---

## [The Perfect Timestamp](https://www.ruby-forum.com/t/the-perfect-timestamp/110686)

<div class="topic-metadata">

**Author:** [@trevorturk](https://www.ruby-forum.com/u/trevorturk)\
**Replies:** 0\
**Last updated:** [July 29, 2007, 5:59pm UTC](https://www.ruby-forum.com/t/the-perfect-timestamp/110686 "2007-07-29T17:59:05Z")

</div>

I just wrote a little piece where I provide some Rails helpers that construct what I believe to be the Holy Grail of timestamps :slight\_smile: http://www.almosteffortless.com/2007/07/29/the-perfect-timestamp/ Perhaps …

---

## [Exif -module reading jpg/raw?](https://www.ruby-forum.com/t/exif-module-reading-jpg-raw/110539)

<div class="topic-metadata">

**Author:** [@davidstokar](https://www.ruby-forum.com/u/davidstokar)\
**Replies:** 2\
**Last updated:** [July 29, 2007, 4:46pm UTC](https://www.ruby-forum.com/t/exif-module-reading-jpg-raw/110539 "2007-07-29T16:46:36Z")

</div>

Hi Does anyone know of any modules that can assist relevant building an application to read data from jpg and raw files for transfer it to a mysql database. I did a search on the ruby and ruby on rails site but fo…

---

## [Reading an email from an mbox file and resending to a differ](https://www.ruby-forum.com/t/reading-an-email-from-an-mbox-file-and-resending-to-a-differ/110683)

<div class="topic-metadata">

**Author:** [@jballanc](https://www.ruby-forum.com/u/jballanc)\
**Replies:** 0\
**Last updated:** [July 29, 2007, 4:25pm UTC](https://www.ruby-forum.com/t/reading-an-email-from-an-mbox-file-and-resending-to-a-differ/110683 "2007-07-29T16:25:35Z")

</div>

Greetings, I’m trying to emulate the “Redirect” function of some email clients but am not having much success. I am sending messages with ActionMailer templates just fine so I’m pretty sure my environment is set up c…

---

## [Select statements](https://www.ruby-forum.com/t/select-statements/110679)

<div class="topic-metadata">

**Author:** [@vanderkerkoff](https://www.ruby-forum.com/u/vanderkerkoff)\
**Replies:** 0\
**Last updated:** [July 29, 2007, 3:27pm UTC](https://www.ruby-forum.com/t/select-statements/110679 "2007-07-29T15:27:30Z")

</div>

Any ideas on this would be great, I’m trying to edit some drop down lists, the collection \_select below does everthing I want it to do and updates the database successfully but doesn’t show the default value of the dr…

---

## [Dynamic form fields](https://www.ruby-forum.com/t/dynamic-form-fields/110502)

<div class="topic-metadata">

**Author:** [@visaolive](https://www.ruby-forum.com/u/visaolive)\
**Replies:** 1\
**Last updated:** [July 29, 2007, 3:16pm UTC](https://www.ruby-forum.com/t/dynamic-form-fields/110502 "2007-07-29T15:16:15Z")

</div>

Hi, i know is a very common problem this one but i have been searching for information about the best way (rails way) of doing this and i haven’t met a good solution: I have a model named Contact that has many phone n…

---

## [Having problems with global variable](https://www.ruby-forum.com/t/having-problems-with-global-variable/110568)

<div class="topic-metadata">

**Author:** [@bloc](https://www.ruby-forum.com/u/bloc)\
**Replies:** 1\
**Last updated:** [July 29, 2007, 2:33pm UTC](https://www.ruby-forum.com/t/having-problems-with-global-variable/110568 "2007-07-29T14:33:21Z")

</div>

Hi all, I am working on a webapp where a user can login, the login process binds with LDAP to see if the user is in LDAP. If its successful, I store the params\[:login\] to a global variable so I can use that in the res…

---

## [Page update](https://www.ruby-forum.com/t/page-update/110668)

<div class="topic-metadata">

**Author:** [@prashanth](https://www.ruby-forum.com/u/prashanth)\
**Replies:** 2\
**Last updated:** [July 29, 2007, 2:22pm UTC](https://www.ruby-forum.com/t/page-update/110668 "2007-07-29T14:22:26Z")

</div>

hi, I am try a ajax helper and the code is \<%= link\_to\_remote “Check Time”, :update =\> ‘current\_time’, :url =\> { :action =\> ‘ncreate’ } %\> and in the action of ncreate i have written a textbox, i can get the te…

---

## [DRYing up between Helper and Controller](https://www.ruby-forum.com/t/drying-up-between-helper-and-controller/110659)

<div class="topic-metadata">

**Author:** [@Kip](https://www.ruby-forum.com/u/Kip)\
**Replies:** 1\
**Last updated:** [July 29, 2007, 1:34pm UTC](https://www.ruby-forum.com/t/drying-up-between-helper-and-controller/110659 "2007-07-29T13:34:57Z")

</div>

I have a few small methods as part of my authorisation scheme, These mostly get used by controllers, but sometimes I want a template to call them too. For example, there are methods called is\_editor?, is\_author? and …

---

## [What are the benefits of REST in plain English?](https://www.ruby-forum.com/t/what-are-the-benefits-of-rest-in-plain-english/110517)

<div class="topic-metadata">

**Author:** [@smc7000](https://www.ruby-forum.com/u/smc7000)\
**Replies:** 16\
**Last updated:** [July 29, 2007, 7:36am UTC](https://www.ruby-forum.com/t/what-are-the-benefits-of-rest-in-plain-english/110517 "2007-07-29T07:36:43Z")

</div>

Can anyone explain the benefits of RESTful design so that a non-programmer will understand? I can’t for the life of me understand why I would want to go through all the trouble of limiting myself to seven methods per …

---

## [No Method Error](https://www.ruby-forum.com/t/no-method-error/110579)

<div class="topic-metadata">

**Author:** [@casper\_the\_ghost](https://www.ruby-forum.com/u/casper_the_ghost)\
**Replies:** 3\
**Last updated:** [July 29, 2007, 7:13am UTC](https://www.ruby-forum.com/t/no-method-error/110579 "2007-07-29T07:13:42Z")

</div>

Hello, I am a long time developer who is new to ruby and rails and am trying to solve a few problems. More than once now have I encountered No Method Errors in my files. In all of the cases, there most definitely is …

---

## [Curious why this doesn't work. (has\_many, belongs\_to)](https://www.ruby-forum.com/t/curious-why-this-doesnt-work-has-many-belongs-to/110664)

<div class="topic-metadata">

**Author:** [@jeannibee](https://www.ruby-forum.com/u/jeannibee)\
**Replies:** 1\
**Last updated:** [July 29, 2007, 4:53am UTC](https://www.ruby-forum.com/t/curious-why-this-doesnt-work-has-many-belongs-to/110664 "2007-07-29T04:53:33Z")

</div>

Two Models. class Gm \< ActiveRecord::Base belongs\_to :pool mode code here. end class Pool \< ActiveRecord::Base has\_many :gms mode code here. end Testing code through the console. gm\_list.each{ | gm | puts " GM …

---

## [Validation](https://www.ruby-forum.com/t/validation/110450)

<div class="topic-metadata">

**Author:** [@xyzt](https://www.ruby-forum.com/u/xyzt)\
**Replies:** 1\
**Last updated:** [July 29, 2007, 4:22am UTC](https://www.ruby-forum.com/t/validation/110450 "2007-07-29T04:22:34Z")

</div>

I prepared a form for adding records to the table. I want the model class to validate the uniqeuness of the name field but it doesn’t give any errors for the duplicate record. Here is the controller : class PetContro…

---

## [Web Settings and different models](https://www.ruby-forum.com/t/web-settings-and-different-models/110663)

<div class="topic-metadata">

**Author:** [@Scott\_Parks](https://www.ruby-forum.com/u/Scott_Parks)\
**Replies:** 0\
**Last updated:** [July 29, 2007, 3:26am UTC](https://www.ruby-forum.com/t/web-settings-and-different-models/110663 "2007-07-29T03:26:30Z")

</div>

I am working on a web app that will have administrator options which in turn will populate a select list on the client side of the application. Being new to Rails I have two questions… I have a table of states and a …

---

## [Scaffold x paginate](https://www.ruby-forum.com/t/scaffold-x-paginate/110658)

<div class="topic-metadata">

**Author:** [@Davi](https://www.ruby-forum.com/u/Davi)\
**Replies:** 0\
**Last updated:** [July 29, 2007, 1:15am UTC](https://www.ruby-forum.com/t/scaffold-x-paginate/110658 "2007-07-29T01:15:23Z")

</div>

Hi all. What am I missing here? \[output\] undefined method \`paginate’ for #AdminController:0xb74bf728 \[/output\] \[admin\_controller.rb\] class AdminController \< ApplicationController scaffold :product end \[/admin\_con…

---

## [How to retrieve response headers in integration tests?](https://www.ruby-forum.com/t/how-to-retrieve-response-headers-in-integration-tests/110588)

<div class="topic-metadata">

**Author:** [@atraeyu](https://www.ruby-forum.com/u/atraeyu)\
**Replies:** 1\
**Last updated:** [July 28, 2007, 11:17pm UTC](https://www.ruby-forum.com/t/how-to-retrieve-response-headers-in-integration-tests/110588 "2007-07-28T23:17:09Z")

</div>

With the code below, the output is “Date is: \[\]”. Why? If I start the server and curl the URL, I get headers that include Last-Modified, yet I cannot retreive them from within the integration tests. What am I doing wr…

---

## [File\_column / rmagick does not generate thumbnails](https://www.ruby-forum.com/t/file-column-rmagick-does-not-generate-thumbnails/110649)

<div class="topic-metadata">

**Author:** [@masone](https://www.ruby-forum.com/u/masone)\
**Replies:** 1\
**Last updated:** [July 28, 2007, 10:22pm UTC](https://www.ruby-forum.com/t/file-column-rmagick-does-not-generate-thumbnails/110649 "2007-07-28T22:22:04Z")

</div>

Hi I am currently setting up my first production environment on a vserver and I ran into a problem with the plugin file\_column, respectively RMagick. The image upload via file\_column works, the file is correctly stor…

---

## [Get 5$ cash for free in your paypal account](https://www.ruby-forum.com/t/get-5-cash-for-free-in-your-paypal-account/110652)

<div class="topic-metadata">

**Author:** [@newbar](https://www.ruby-forum.com/u/newbar)\
**Replies:** 0\
**Last updated:** [July 28, 2007, 10:18pm UTC](https://www.ruby-forum.com/t/get-5-cash-for-free-in-your-paypal-account/110652 "2007-07-28T22:18:04Z")

</div>

get 5$ cash for free in your paypal account Our system paid you 0.05$ every click on your paid link at the sign up you got 5$ in bonus and you can get more with your Referral Links. But don’t forget to click every da…

---

## [Cap2 hangs in the shell](https://www.ruby-forum.com/t/cap2-hangs-in-the-shell/110644)

<div class="topic-metadata">

**Author:** [@dxk3355](https://www.ruby-forum.com/u/dxk3355)\
**Replies:** 2\
**Last updated:** [July 28, 2007, 10:09pm UTC](https://www.ruby-forum.com/t/cap2-hangs-in-the-shell/110644 "2007-07-28T22:09:18Z")

</div>

Hi, I’m having trouble with testing/learning capistrano… I failed at the first thing I wanted to do… here: david@local:~$ cap shell HOSTS=server1 executing \`shell’ ==================================================…

---

## [Nested RESTful Routes and creating a object from XML](https://www.ruby-forum.com/t/nested-restful-routes-and-creating-a-object-from-xml/110651)

<div class="topic-metadata">

**Author:** [@supasta](https://www.ruby-forum.com/u/supasta)\
**Replies:** 0\
**Last updated:** [July 28, 2007, 10:05pm UTC](https://www.ruby-forum.com/t/nested-restful-routes-and-creating-a-object-from-xml/110651 "2007-07-28T22:05:22Z")

</div>

I am trying to create a new model from XML that contains has a has\_many relationship. Is this possible without having to write code to parse the XML or to doing multiple POSTS? I can do a post with XML that doesn’t …

---

## [Attachment\_fu destroy](https://www.ruby-forum.com/t/attachment-fu-destroy/110646)

<div class="topic-metadata">

**Author:** [@Acroterra](https://www.ruby-forum.com/u/Acroterra)\
**Replies:** 0\
**Last updated:** [July 28, 2007, 8:37pm UTC](https://www.ruby-forum.com/t/attachment-fu-destroy/110646 "2007-07-28T20:37:55Z")

</div>

I am using attachment\_fu to upload images and I am using the filesystem to store the images. Does anybody know how to delete the image file in the filesystem when an image object is destroyed?? This way I won’t have a…

---

## [Ruby on Rails & Textmate](https://www.ruby-forum.com/t/ruby-on-rails-textmate/110605)

<div class="topic-metadata">

**Author:** [@irock](https://www.ruby-forum.com/u/irock)\
**Replies:** 7\
**Last updated:** [July 28, 2007, 7:28pm UTC](https://www.ruby-forum.com/t/ruby-on-rails-textmate/110605 "2007-07-28T19:28:40Z")

</div>

I’m new to textmate also and I was wondering how can you get it to integrate with the Ruby on Rails. I know there is like a “popout with navigation for the folders” - the best way I can describe it. How can I get thi…

---

## [Defining own exceptions in rails](https://www.ruby-forum.com/t/defining-own-exceptions-in-rails/110638)

<div class="topic-metadata">

**Author:** [@andreim](https://www.ruby-forum.com/u/andreim)\
**Replies:** 1\
**Last updated:** [July 28, 2007, 5:49pm UTC](https://www.ruby-forum.com/t/defining-own-exceptions-in-rails/110638 "2007-07-28T17:49:29Z")

</div>

Hi, I would like to define my own exceptions in rails. I would like these definitions to be available throughout my application. What’s an elegant/good way to do this? The only way I can think of doing this is by put…

---

## [Rails bug with partials and charsets?](https://www.ruby-forum.com/t/rails-bug-with-partials-and-charsets/107703)

<div class="topic-metadata">

**Author:** [@msojka](https://www.ruby-forum.com/u/msojka)\
**Replies:** 2\
**Last updated:** [July 28, 2007, 5:47pm UTC](https://www.ruby-forum.com/t/rails-bug-with-partials-and-charsets/107703 "2007-07-28T17:47:28Z")

</div>

Hi, Is there a bug with the use of partials and how the input from forms is handled? My app is working fine if I use a plain view and form\_tag, but as soon as I switch to partials and form\_remote\_tag I’m not able to …

---

## [Activerecord model constantize question](https://www.ruby-forum.com/t/activerecord-model-constantize-question/110636)

<div class="topic-metadata">

**Author:** [@izit](https://www.ruby-forum.com/u/izit)\
**Replies:** 2\
**Last updated:** [July 28, 2007, 5:42pm UTC](https://www.ruby-forum.com/t/activerecord-model-constantize-question/110636 "2007-07-28T17:42:28Z")

</div>

I have a variable called column with the value of “bla” (column = “bla”) I have a model call Location where method bla is defined (amongst many other methods). What I would like to to is to call the method in Locatio…

---

## [Capistrano "No such file or directory" error](https://www.ruby-forum.com/t/capistrano-no-such-file-or-directory-error/109475)

<div class="topic-metadata">

**Author:** [@jseidel](https://www.ruby-forum.com/u/jseidel)\
**Replies:** 2\
**Last updated:** [July 28, 2007, 5:30pm UTC](https://www.ruby-forum.com/t/capistrano-no-such-file-or-directory-error/109475 "2007-07-28T17:30:26Z")

</div>

For some reason, I can’t get my cap deploy to work… I keep getting the error: C:\\Dev\\InstantRails\\rails\_apps\\4MyPasswords\>cap deploy executing task deploy executing task update \*\* transaction: start executing…

---

## [ActiveRecord validates\_presence\_of with false](https://www.ruby-forum.com/t/activerecord-validates-presence-of-with-false/110621)

<div class="topic-metadata">

**Author:** [@Hendy\_I](https://www.ruby-forum.com/u/Hendy_I)\
**Replies:** 1\
**Last updated:** [July 28, 2007, 5:20pm UTC](https://www.ruby-forum.com/t/activerecord-validates-presence-of-with-false/110621 "2007-07-28T17:20:25Z")

</div>

Hi Rails I can’t seem to use a boolean value ‘false’ with validates\_presence\_of. It always fails. I even tried using ‘f’. What’s the proper way to set a false value? Isn’t false a “present” value in a boolean column…

---

## [Nooby Help with created\_at, updated\_at, and if/then](https://www.ruby-forum.com/t/nooby-help-with-created-at-updated-at-and-if-then/110587)

<div class="topic-metadata">

**Author:** [@hailandkill](https://www.ruby-forum.com/u/hailandkill)\
**Replies:** 7\
**Last updated:** [July 28, 2007, 5:16pm UTC](https://www.ruby-forum.com/t/nooby-help-with-created-at-updated-at-and-if-then/110587 "2007-07-28T17:16:24Z")

</div>

Hola. I’m super-new to actually doing things in rails and with ruby, so pardon me if this is an easy question to everyone else. I’m making a web app, and at this time am designing the news/blog portion of it. I have a…

---

## [Windows + linux?](https://www.ruby-forum.com/t/windows-linux/110585)

<div class="topic-metadata">

**Author:** [@ming](https://www.ruby-forum.com/u/ming)\
**Replies:** 12\
**Last updated:** [July 28, 2007, 3:16pm UTC](https://www.ruby-forum.com/t/windows-linux/110585 "2007-07-28T15:16:22Z")

</div>

i’m playing with rails as a personal side project and could use some advice on setting up a productive development platform. the target for the project is linux. for development, i have access to windows pcs and the…

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

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