# Rails

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

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

---

## [Installation options for rails?](https://www.ruby-forum.com/t/installation-options-for-rails/191933)

<div class="topic-metadata">

**Author:** [@casper\_the\_ghost](https://www.ruby-forum.com/u/casper_the_ghost)\
**Replies:** 2\
**Last updated:** [July 22, 2010, 8:31pm UTC](https://www.ruby-forum.com/t/installation-options-for-rails/191933 "2010-07-22T20:31:21Z")

</div>

i am running windows vista and am working on the download of ruby and rails…so heres what i just did …I downloaded and installed ruby 1.9.1-p429 then I downloaded and installed rubygems 1.3.7 …my next question: wou…

---

## [Displaying the sum](https://www.ruby-forum.com/t/displaying-the-sum/192018)

<div class="topic-metadata">

**Author:** [@swengineer](https://www.ruby-forum.com/u/swengineer)\
**Replies:** 6\
**Last updated:** [July 22, 2010, 7:45pm UTC](https://www.ruby-forum.com/t/displaying-the-sum/192018 "2010-07-22T19:45:32Z")

</div>

I’m creating a very simple Rails application where I enter “First number” and then “Second number” and get the result in the “Sum”. Those are some files: show.html.erb: http://pastie.org/private/1cydign77xnijlrb7mjvng …

---

## [Autocomplete - Search Multiple Tables](https://www.ruby-forum.com/t/autocomplete-search-multiple-tables/192035)

<div class="topic-metadata">

**Author:** [@asherwood](https://www.ruby-forum.com/u/asherwood)\
**Replies:** 0\
**Last updated:** [July 22, 2010, 6:26pm UTC](https://www.ruby-forum.com/t/autocomplete-search-multiple-tables/192035 "2010-07-22T18:26:52Z")

</div>

I’m trying to implement Autocomplete on my site and allow customers to search for restaurants by name or city all from one search box. I can’t seem how to get one edit field to interact with Autocomplete from multiple…

---

## [Configuring GIT repository on dreamhost - novice](https://www.ruby-forum.com/t/configuring-git-repository-on-dreamhost-novice/192017)

<div class="topic-metadata">

**Author:** [@sachin](https://www.ruby-forum.com/u/sachin)\
**Replies:** 2\
**Last updated:** [July 22, 2010, 5:54pm UTC](https://www.ruby-forum.com/t/configuring-git-repository-on-dreamhost-novice/192017 "2010-07-22T17:54:20Z")

</div>

Hello Experts, I am trying to host a git repository in dreamhost, have a pre installed git version 1.5.4.1 on the server. I have referred to many sites on which a lot of information given. http://www.winstonyw.com/2…

---

## [Starting with RoR](https://www.ruby-forum.com/t/starting-with-ror/192031)

<div class="topic-metadata">

**Author:** [@disruptive](https://www.ruby-forum.com/u/disruptive)\
**Replies:** 4\
**Last updated:** [July 22, 2010, 4:47pm UTC](https://www.ruby-forum.com/t/starting-with-ror/192031 "2010-07-22T16:47:00Z")

</div>

A newbie on Rails… I am quite experienced at developing fully fledged sites in a variety of languages - but mainly based around .NET and perl \[not together :-)\]. I am considering deploying a new solution in RoR and th…

---

## [DRY a named scope](https://www.ruby-forum.com/t/dry-a-named-scope/190680)

<div class="topic-metadata">

**Author:** [@bigdaddy71](https://www.ruby-forum.com/u/bigdaddy71)\
**Replies:** 3\
**Last updated:** [July 22, 2010, 3:52pm UTC](https://www.ruby-forum.com/t/dry-a-named-scope/190680 "2010-07-22T15:52:33Z")

</div>

Is there a way to DRY this up a bit? named\_scope :has\_valid\_sysoid, lambda{|sysoid| (sysoid.nil?) ? {:conditions =\> \[“nodesysoid IS NOT NULL AND nodelabel LIKE ‘%-to-%’”\], :include =\> \[:ipinterface, :alarm\]} : {:cond…

---

## [Recaptcha accepting one word out of two](https://www.ruby-forum.com/t/recaptcha-accepting-one-word-out-of-two/192028)

<div class="topic-metadata">

**Author:** [@amitjain](https://www.ruby-forum.com/u/amitjain)\
**Replies:** 1\
**Last updated:** [July 22, 2010, 3:47pm UTC](https://www.ruby-forum.com/t/recaptcha-accepting-one-word-out-of-two/192028 "2010-07-22T15:47:16Z")

</div>

Hi , I am a bit confused about how recaptcha works. I have implemented it using ROR. Sometimes even if i specify only one word out of two, it returns true while sometimes it fails. I am really confused and not able …

---

## [\[RAILS\] truncate only works local, after deploy it does nothing](https://www.ruby-forum.com/t/rails-truncate-only-works-local-after-deploy-it-does-nothing/192022)

<div class="topic-metadata">

**Author:** [@nymo](https://www.ruby-forum.com/u/nymo)\
**Replies:** 0\
**Last updated:** [July 22, 2010, 2:18pm UTC](https://www.ruby-forum.com/t/rails-truncate-only-works-local-after-deploy-it-does-nothing/192022 "2010-07-22T14:18:15Z")

</div>

Hi all, i have strange problem. On my site i have a teaser for an article. This teaser is truncated after 200 letters. On my local machine it works perfect. After i deploy my application on the serverside, nothing is …

---

## [Setting up a VPS with Nginx, Rails and FTP](https://www.ruby-forum.com/t/setting-up-a-vps-with-nginx-rails-and-ftp/192006)

<div class="topic-metadata">

**Author:** [@paulbutcher](https://www.ruby-forum.com/u/paulbutcher)\
**Replies:** 0\
**Last updated:** [July 22, 2010, 10:53am UTC](https://www.ruby-forum.com/t/setting-up-a-vps-with-nginx-rails-and-ftp/192006 "2010-07-22T10:53:45Z")

</div>

I have a new VPS with Debian 5 where I’m going to move my sites. I have installed Rails and Nginx with Passenger. I’m a single user. How should I setup user, html-root (now in /opt/nginx/html), ftp (with proftpd) so I…

---

## [Send picture from iPhone](https://www.ruby-forum.com/t/send-picture-from-iphone/191983)

<div class="topic-metadata">

**Author:** [@AndrSSSS](https://www.ruby-forum.com/u/AndrSSSS)\
**Replies:** 1\
**Last updated:** [July 22, 2010, 10:11am UTC](https://www.ruby-forum.com/t/send-picture-from-iphone/191983 "2010-07-22T10:11:09Z")

</div>

I’m working on a project that needs a picture taken from an iPhone to be sent to a Rails back end, which uses paperclip. I’m trying to send it via http post but i get the following error: We’re sorry, but something we…

---

## [= sign at end of plain text sent by mailer](https://www.ruby-forum.com/t/sign-at-end-of-plain-text-sent-by-mailer/191968)

<div class="topic-metadata">

**Author:** [@himdel](https://www.ruby-forum.com/u/himdel)\
**Replies:** 2\
**Last updated:** [July 22, 2010, 10:07am UTC](https://www.ruby-forum.com/t/sign-at-end-of-plain-text-sent-by-mailer/191968 "2010-07-22T10:07:03Z")

</div>

Rails v2.3.8; Ruby v1.8.7 When sending a plain text email using ActionMailer, the email contains = signs at the end of long lines. This is a problem as I’m including a link which is bound to break over more than one …

---

## [\[Jobs\] RoR Developer Needed - BarZ Adventures (Austin, TX)](https://www.ruby-forum.com/t/jobs-ror-developer-needed-barz-adventures-austin-tx/192005)

<div class="topic-metadata">

**Author:** [@BarZ\_Adventures](https://www.ruby-forum.com/u/BarZ_Adventures)\
**Replies:** 0\
**Last updated:** [July 22, 2010, 9:03am UTC](https://www.ruby-forum.com/t/jobs-ror-developer-needed-barz-adventures-austin-tx/192005 "2010-07-22T09:03:49Z")

</div>

Hello, BarZ Adventures is an Austin-based start-up company that creates location-aware tour technology. We are looking for a software developer to work on our Ruby-on-Rails web application. The application also se…

---

## [Rails + Google Maps 3 plugin](https://www.ruby-forum.com/t/rails-google-maps-3-plugin/192000)

<div class="topic-metadata">

**Author:** [@Manos](https://www.ruby-forum.com/u/Manos)\
**Replies:** 0\
**Last updated:** [July 22, 2010, 8:49am UTC](https://www.ruby-forum.com/t/rails-google-maps-3-plugin/192000 "2010-07-22T08:49:11Z")

</div>

Hi, I would like to ask if there is a plugin compatible with new Google Maps Api 3. I would like to use api 3 instead of 2 as it has better geocoding and reverse geocoding capabilities. Thank you in advance

---

## [Rails partials violate javascripts "same origin policy"?](https://www.ruby-forum.com/t/rails-partials-violate-javascripts-same-origin-policy/191970)

<div class="topic-metadata">

**Author:** [@brandentanga](https://www.ruby-forum.com/u/brandentanga)\
**Replies:** 2\
**Last updated:** [July 22, 2010, 7:23am UTC](https://www.ruby-forum.com/t/rails-partials-violate-javascripts-same-origin-policy/191970 "2010-07-22T07:23:23Z")

</div>

Hello, In my rails application.html.erb, I have in javascript, an ajax post call defined in a dom element’s click method. This ajax call works fine whenever I’m at a view that is a standard render. However, whenever I…

---

## [Simple syntax error(its urgent)unable 2 find](https://www.ruby-forum.com/t/simple-syntax-error-its-urgent-unable-2-find/191998)

<div class="topic-metadata">

**Author:** [@murfhy](https://www.ruby-forum.com/u/murfhy)\
**Replies:** 0\
**Last updated:** [July 22, 2010, 7:07am UTC](https://www.ruby-forum.com/t/simple-syntax-error-its-urgent-unable-2-find/191998 "2010-07-22T07:07:26Z")

</div>

i have created an appliation to show the pie chart in pdf, now its showing properly, but the thing is that its not showing the labels correctly, can anyone help me, pdf of tht ia attached with this. also i …

---

## [Bad content body on MC FF](https://www.ruby-forum.com/t/bad-content-body-on-mc-ff/191997)

<div class="topic-metadata">

**Author:** [@saurabhpurnaye](https://www.ruby-forum.com/u/saurabhpurnaye)\
**Replies:** 0\
**Last updated:** [July 22, 2010, 6:52am UTC](https://www.ruby-forum.com/t/bad-content-body-on-mc-ff/191997 "2010-07-22T06:52:34Z")

</div>

Hi All, I’m getting the following error in my production.log when I try to upload a file from MAC FF. On rest of the browsers file uploading is working fine. Rendering /home5/folder\_namete/Portfolio/application\_name…

---

## [Gem for displaying international postal addresses?](https://www.ruby-forum.com/t/gem-for-displaying-international-postal-addresses/191949)

<div class="topic-metadata">

**Author:** [@nosretep](https://www.ruby-forum.com/u/nosretep)\
**Replies:** 2\
**Last updated:** [July 22, 2010, 5:57am UTC](https://www.ruby-forum.com/t/gem-for-displaying-international-postal-addresses/191949 "2010-07-22T05:57:39Z")

</div>

Is there a Gem that can be utilized for displaying postal addresses in the format specific to their destination country or region? Basically, a Gem that programatically does what this site advises? Anything similar? …

---

## [Anyway for a model to call url\_for?](https://www.ruby-forum.com/t/anyway-for-a-model-to-call-url-for/100547)

<div class="topic-metadata">

**Author:** [@Brittain](https://www.ruby-forum.com/u/Brittain)\
**Replies:** 6\
**Last updated:** [July 22, 2010, 2:05am UTC](https://www.ruby-forum.com/t/anyway-for-a-model-to-call-url-for/100547 "2010-07-22T02:05:36Z")

</div>

Or better yet, a named route? Tried lots of searches and ugly hacks … Thanks in advance.

---

## [Generating RDoc for App](https://www.ruby-forum.com/t/generating-rdoc-for-app/191972)

<div class="topic-metadata">

**Author:** [@willclarkdesigns](https://www.ruby-forum.com/u/willclarkdesigns)\
**Replies:** 5\
**Last updated:** [July 22, 2010, 12:48am UTC](https://www.ruby-forum.com/t/generating-rdoc-for-app/191972 "2010-07-22T00:48:51Z")

</div>

I notice that when I run rake doc:app, that the named\_scope declarations I have in my models aren’t being included in the documentation. Is there a way to get named\_scopes in the rdocs? Thanks, Will

---

## [Many to many relations](https://www.ruby-forum.com/t/many-to-many-relations/191865)

<div class="topic-metadata">

**Author:** [@Solidify](https://www.ruby-forum.com/u/Solidify)\
**Replies:** 9\
**Last updated:** [July 21, 2010, 11:35pm UTC](https://www.ruby-forum.com/t/many-to-many-relations/191865 "2010-07-21T23:35:23Z")

</div>

Hi everyone, I have a simple question: an author has a place of birth and a place of death. Both places should come from the same table (cities). This should be a many\_to\_many relationship, because one author may be b…

---

## [Render :js =\> "alert('Test !')"](https://www.ruby-forum.com/t/render-js-alert-test/191922)

<div class="topic-metadata">

**Author:** [@mamadoutoure](https://www.ruby-forum.com/u/mamadoutoure)\
**Replies:** 20\
**Last updated:** [July 21, 2010, 11:15pm UTC](https://www.ruby-forum.com/t/render-js-alert-test/191922 "2010-07-21T23:15:44Z")

</div>

Hi Folks, I use render :js =\> “alert(‘Test !’)” in my modele, but instead of having the alert displayed, the browser try to donload a file containing this string : \<\<render :js =\> “alert(‘Test !’)”\>\>. Do you know why …

---

## [Produce html flash message with csv action](https://www.ruby-forum.com/t/produce-html-flash-message-with-csv-action/191974)

<div class="topic-metadata">

**Author:** [@bigdaddy71](https://www.ruby-forum.com/u/bigdaddy71)\
**Replies:** 1\
**Last updated:** [July 21, 2010, 9:50pm UTC](https://www.ruby-forum.com/t/produce-html-flash-message-with-csv-action/191974 "2010-07-21T21:50:00Z")

</div>

How would I produce an HTML flash message on the screen if I call an action.csv in the page?

---

## [Cgi\_process.rb:22:in \`\_\_send\_\_': undefined method \`env\_table](https://www.ruby-forum.com/t/cgi-process-rbin-send-undefined-method-env-table/191984)

<div class="topic-metadata">

**Author:** [@jfgg](https://www.ruby-forum.com/u/jfgg)\
**Replies:** 0\
**Last updated:** [July 21, 2010, 9:13pm UTC](https://www.ruby-forum.com/t/cgi-process-rbin-send-undefined-method-env-table/191984 "2010-07-21T21:13:57Z")

</div>

.htaccess is like this… AddHandler fcgid-script .fcgi RewriteRule ^$ index.html \[QSA\] RewriteRule ^(\[^.\]+)$ $1.html \[QSA\] RewriteCond %{REQUEST\_FILENAME} !-f #RewriteRule ^(.)$ dispatch.cgi \[QSA,L\] \<— commented Re…

---

## [IDs problem](https://www.ruby-forum.com/t/ids-problem/191975)

<div class="topic-metadata">

**Author:** [@lilyweb](https://www.ruby-forum.com/u/lilyweb)\
**Replies:** 5\
**Last updated:** [July 21, 2010, 6:40pm UTC](https://www.ruby-forum.com/t/ids-problem/191975 "2010-07-21T18:40:30Z")

</div>

Hi, I have a model “Theme” which has\_and\_belongs\_to\_many “Lessons”. I need to get the (db) id of the lessons through the theme. For instance, if in irb I write something like this : test = Theme.find(:first) puts te…

---

## [Seeking Cofounder (aka ninja, rockstar, superman, etc)](https://www.ruby-forum.com/t/seeking-cofounder-aka-ninja-rockstar-superman-etc/191625)

<div class="topic-metadata">

**Author:** [@aaronpowell](https://www.ruby-forum.com/u/aaronpowell)\
**Replies:** 3\
**Last updated:** [July 21, 2010, 3:15pm UTC](https://www.ruby-forum.com/t/seeking-cofounder-aka-ninja-rockstar-superman-etc/191625 "2010-07-21T15:15:39Z")

</div>

Hello, I’m working on a new web project and I’m looking for a technical cofounder. I’ve had a few startups before (both successful and otherwise) and outsourced the web development. However, this time I really want…

---

## [Using form\_tag inside a helper](https://www.ruby-forum.com/t/using-form-tag-inside-a-helper/84958)

<div class="topic-metadata">

**Author:** [@BallS\_Donald\_A\_Jr\_S](https://www.ruby-forum.com/u/BallS_Donald_A_Jr_S)\
**Replies:** 4\
**Last updated:** [July 21, 2010, 2:46pm UTC](https://www.ruby-forum.com/t/using-form-tag-inside-a-helper/84958 "2010-07-21T14:46:49Z")

</div>

The proper usage of form\_tag nowadays is: \<% form\_tag do %\> blah blah blah \<% end %\> Supposing I want to use form\_tag inside a helper, e.g. def search\_form form\_tag do … ??? … end end what would I put inside th…

---

## [Rails rake - setting constant and cache delete](https://www.ruby-forum.com/t/rails-rake-setting-constant-and-cache-delete/191969)

<div class="topic-metadata">

**Author:** [@aldoitalo](https://www.ruby-forum.com/u/aldoitalo)\
**Replies:** 0\
**Last updated:** [July 21, 2010, 2:12pm UTC](https://www.ruby-forum.com/t/rails-rake-setting-constant-and-cache-delete/191969 "2010-07-21T14:12:15Z")

</div>

i perform a rake task with a cron, in this task i have 2 problems: -i using a constant name setting in my config/environment.rb, when i try to run the rake job on the “environment developer” the constant is read an th…

---

## [Rails + Google Maps 3](https://www.ruby-forum.com/t/rails-google-maps-3/191963)

<div class="topic-metadata">

**Author:** [@sifix](https://www.ruby-forum.com/u/sifix)\
**Replies:** 0\
**Last updated:** [July 21, 2010, 11:32am UTC](https://www.ruby-forum.com/t/rails-google-maps-3/191963 "2010-07-21T11:32:03Z")

</div>

Hi, I would like to ask if there is a plugin compatible with new Google Maps Api 3. I would like to use api 3 instead of 2 as it has better geocoding and reverse geocoding capabilities. Thank you in advance

---

## [\<%=h...%\>](https://www.ruby-forum.com/t/h/191943)

<div class="topic-metadata">

**Author:** [@swengineer](https://www.ruby-forum.com/u/swengineer)\
**Replies:** 5\
**Last updated:** [July 21, 2010, 11:02am UTC](https://www.ruby-forum.com/t/h/191943 "2010-07-21T11:02:45Z")

</div>

In the “Head First Rails” book, it mentions that “h” in \<%=h…%\> is a helper method. Can someone describe what that means? And, when should I use \<%=h…%\>? Is it when I want the result to be displayed on my view for exa…

---

## [Setup not invoked during unit testing](https://www.ruby-forum.com/t/setup-not-invoked-during-unit-testing/191914)

<div class="topic-metadata">

**Author:** [@f2andy](https://www.ruby-forum.com/u/f2andy)\
**Replies:** 3\
**Last updated:** [July 21, 2010, 10:33am UTC](https://www.ruby-forum.com/t/setup-not-invoked-during-unit-testing/191914 "2010-07-21T10:33:41Z")

</div>

I have a bunch of unit test files in a Rails project. One of them has stopped using the setup method before each test, or even if I invoke it in the test itself. After commenting out most of it, here is what is left: …

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

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