# Rails

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

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

---

## [Ultrasphinx geolookup distance returns NaN value](https://www.ruby-forum.com/t/ultrasphinx-geolookup-distance-returns-nan-value/138781)

<div class="topic-metadata">

**Author:** [@veeraa2003](https://www.ruby-forum.com/u/veeraa2003)\
**Replies:** 0\
**Last updated:** [May 27, 2008, 5:53pm UTC](https://www.ruby-forum.com/t/ultrasphinx-geolookup-distance-returns-nan-value/138781 "2008-05-27T17:53:00Z")

</div>

Hi all, I’m trying to use geo-location based search using sphinx, Here my search query. @search = Ultrasphinx::Search.new(:sort\_mode =\> ‘extended’, :sort\_by =\> ‘distance’, :location =\> {:units =\> ‘degrees’, :lat =\> 4…

---

## [Time based fragement caching](https://www.ruby-forum.com/t/time-based-fragement-caching/138782)

<div class="topic-metadata">

**Author:** [@aditya](https://www.ruby-forum.com/u/aditya)\
**Replies:** 0\
**Last updated:** [May 27, 2008, 5:50pm UTC](https://www.ruby-forum.com/t/time-based-fragement-caching/138782 "2008-05-27T17:50:59Z")

</div>

Hi Guys, I googled and found that time based fragment caching isnt something out of the box. No worries, I’m sure someone wrote a plugin for it. Any pointers? Whats the preferred pattern / technique for implementing …

---

## [Ultrasphinx geolookup distance returns NaN value](https://www.ruby-forum.com/t/ultrasphinx-geolookup-distance-returns-nan-value/138780)

<div class="topic-metadata">

**Author:** [@veeraa2003](https://www.ruby-forum.com/u/veeraa2003)\
**Replies:** 0\
**Last updated:** [May 27, 2008, 5:43pm UTC](https://www.ruby-forum.com/t/ultrasphinx-geolookup-distance-returns-nan-value/138780 "2008-05-27T17:43:31Z")

</div>

Hi all, I’m trying to use geo-location based search using sphinx, Here my search query. @search = Ultrasphinx::Search.new(:sort\_mode =\> ‘extended’, :sort\_by =\> ‘distance’, :location =\> {:units =\> ‘degrees’, :lat =\> 4…

---

## [Mongrel\_cluster / cleanup of pid files / --clean why not a default?](https://www.ruby-forum.com/t/mongrel-cluster-cleanup-of-pid-files-clean-why-not-a-default/138778)

<div class="topic-metadata">

**Author:** [@aditya](https://www.ruby-forum.com/u/aditya)\
**Replies:** 0\
**Last updated:** [May 27, 2008, 5:30pm UTC](https://www.ruby-forum.com/t/mongrel-cluster-cleanup-of-pid-files-clean-why-not-a-default/138778 "2008-05-27T17:30:50Z")

</div>

Hi Guys, After trying to come up with a solution for a problem whose solution existed all that while, i wish to ask why its not really a default in the first place? Often, mongrels on our server crash (we’re looking …

---

## [Order complex aggregation results in 'calculate'](https://www.ruby-forum.com/t/order-complex-aggregation-results-in-calculate/138770)

<div class="topic-metadata">

**Author:** [@duco](https://www.ruby-forum.com/u/duco)\
**Replies:** 2\
**Last updated:** [May 27, 2008, 5:05pm UTC](https://www.ruby-forum.com/t/order-complex-aggregation-results-in-calculate/138770 "2008-05-27T17:05:59Z")

</div>

Hi, How would you order the results of a complex aggregation using ‘calculate’ (from ActiveRecord::Calculations::ClassMethod)? I have a “legacy” table from which I would like to retrieve some aggregated data, with an…

---

## [Depends\_on polymorphic association](https://www.ruby-forum.com/t/depends-on-polymorphic-association/138768)

<div class="topic-metadata">

**Author:** [@starmaerker](https://www.ruby-forum.com/u/starmaerker)\
**Replies:** 0\
**Last updated:** [May 27, 2008, 4:15pm UTC](https://www.ruby-forum.com/t/depends-on-polymorphic-association/138768 "2008-05-27T16:15:37Z")

</div>

Hello everyone, So I wrote this little piece of code: http://blog.stonean.com/2008/05/dependson.html Sorry for the blog link, but this was necessary for code formatting and long description. Anyway, I just wanted t…

---

## [Dynamic methods for copying objects](https://www.ruby-forum.com/t/dynamic-methods-for-copying-objects/138759)

<div class="topic-metadata">

**Author:** [@johnnybutler7](https://www.ruby-forum.com/u/johnnybutler7)\
**Replies:** 3\
**Last updated:** [May 27, 2008, 4:12pm UTC](https://www.ruby-forum.com/t/dynamic-methods-for-copying-objects/138759 "2008-05-27T16:12:04Z")

</div>

Hi, I was wondering if this is possible. dyn\_method = “roles” Object1 = User.find(1) object2 = User.find(2) object1.dyn\_method = object2.dyn\_method So what im going to have is a load of strings coming in which are …

---

## [Problems With Rails Deployment](https://www.ruby-forum.com/t/problems-with-rails-deployment/137799)

<div class="topic-metadata">

**Author:** [@yetanothergeek](https://www.ruby-forum.com/u/yetanothergeek)\
**Replies:** 2\
**Last updated:** [May 27, 2008, 3:46pm UTC](https://www.ruby-forum.com/t/problems-with-rails-deployment/137799 "2008-05-27T15:46:02Z")

</div>

Good Afternoon, I am fairly new to Ruby on Rails and im am having countless problems with the deployment of a eccommerce site onto a linux server, i am currently onto my second hosting company (www.eukhost.com) and ha…

---

## [HABTM using two columns](https://www.ruby-forum.com/t/habtm-using-two-columns/138747)

<div class="topic-metadata">

**Author:** [@meisterflexer](https://www.ruby-forum.com/u/meisterflexer)\
**Replies:** 2\
**Last updated:** [May 27, 2008, 3:22pm UTC](https://www.ruby-forum.com/t/habtm-using-two-columns/138747 "2008-05-27T15:22:22Z")

</div>

Hi all, I was wondering whether anyone could guide me to docu and code examples how to create and use a has\_and\_belongs\_to\_many relationship with a joining table where TWO columns are used to identify the relation to…

---

## [Newbie: Wierd ID not routing by default problem](https://www.ruby-forum.com/t/newbie-wierd-id-not-routing-by-default-problem/138756)

<div class="topic-metadata">

**Author:** [@oshuma](https://www.ruby-forum.com/u/oshuma)\
**Replies:** 2\
**Last updated:** [May 27, 2008, 2:28pm UTC](https://www.ruby-forum.com/t/newbie-wierd-id-not-routing-by-default-problem/138756 "2008-05-27T14:28:02Z")

</div>

Ok so I was having this problem before and thought Id start again from scratch. Here is an example of my index.html.erb file \<% for user in @users %\> \<%= h user.SurName %\> \<%= h user.ForeName %\> \<td\>\<%= li…

---

## [Nil Object](https://www.ruby-forum.com/t/nil-object/138740)

<div class="topic-metadata">

**Author:** [@hloooi](https://www.ruby-forum.com/u/hloooi)\
**Replies:** 3\
**Last updated:** [May 27, 2008, 2:07pm UTC](https://www.ruby-forum.com/t/nil-object/138740 "2008-05-27T14:07:56Z")

</div>

well, im tryin to read an email, which already is a txt file in my folder, which name is ForActionMailer, but when i run the command it shows this error C:\\rubydev\\prac1\\mail5\>ruby script/runner EventMailer.receive(S…

---

## [Before\_create event or method](https://www.ruby-forum.com/t/before-create-event-or-method/138725)

<div class="topic-metadata">

**Author:** [@pankaj](https://www.ruby-forum.com/u/pankaj)\
**Replies:** 1\
**Last updated:** [May 27, 2008, 1:53pm UTC](https://www.ruby-forum.com/t/before-create-event-or-method/138725 "2008-05-27T13:53:51Z")

</div>

I have multiple models which have certain(same) action(let us call it action1) to be performed on before\_create, and other common funcionallity. Also in only certain model action2 is also to be performed. class Model…

---

## [Rmagic not crop graphics interchange format image properly](https://www.ruby-forum.com/t/rmagic-not-crop-graphics-interchange-format-image-properly/196693)

<div class="topic-metadata">

**Author:** [@sunfish](https://www.ruby-forum.com/u/sunfish)\
**Replies:** 0\
**Last updated:** [May 27, 2008, 12:38pm UTC](https://www.ruby-forum.com/t/rmagic-not-crop-graphics-interchange-format-image-properly/196693 "2008-05-27T12:38:00Z")

</div>

Rmagic not crop graphics interchange format image properly. so how to do this?

---

## [Rmagic not crop graphics interchange format image](https://www.ruby-forum.com/t/rmagic-not-crop-graphics-interchange-format-image/138744)

<div class="topic-metadata">

**Author:** [@sunfish](https://www.ruby-forum.com/u/sunfish)\
**Replies:** 0\
**Last updated:** [May 27, 2008, 12:37pm UTC](https://www.ruby-forum.com/t/rmagic-not-crop-graphics-interchange-format-image/138744 "2008-05-27T12:37:18Z")

</div>

Rmagic not crop graphics interchange format image properly. so how to do this?

---

## [Envelopes using ActionMailer](https://www.ruby-forum.com/t/envelopes-using-actionmailer/138742)

<div class="topic-metadata">

**Author:** [@shankar](https://www.ruby-forum.com/u/shankar)\
**Replies:** 6\
**Last updated:** [May 27, 2008, 12:36pm UTC](https://www.ruby-forum.com/t/envelopes-using-actionmailer/138742 "2008-05-27T12:36:39Z")

</div>

Hello, I have been developing a web application using ROR (hosted on webricks/windows) which makes use of ActionMailer to send out mails to various mailing lists. Recently, we came across a use case which required th…

---

## [Doesn't create my guestbook](https://www.ruby-forum.com/t/doesnt-create-my-guestbook/138657)

<div class="topic-metadata">

**Author:** [@kaizerkaizer](https://www.ruby-forum.com/u/kaizerkaizer)\
**Replies:** 11\
**Last updated:** [May 27, 2008, 12:22pm UTC](https://www.ruby-forum.com/t/doesnt-create-my-guestbook/138657 "2008-05-27T12:22:37Z")

</div>

Hi, I’m having some trouble with my realtions (I think). I’m creating a guestbook with comments in ajax (the structure resembles the structure of a blog). So I’ve got a “flogs table” which keeps the “user\_id” and the…

---

## [Uninitialized constant Net::SSH](https://www.ruby-forum.com/t/uninitialized-constant-net-ssh/138743)

<div class="topic-metadata">

**Author:** [@imonike](https://www.ruby-forum.com/u/imonike)\
**Replies:** 2\
**Last updated:** [May 27, 2008, 12:15pm UTC](https://www.ruby-forum.com/t/uninitialized-constant-net-ssh/138743 "2008-05-27T12:15:27Z")

</div>

Hello everyone, Pls i am a newbie to Ruby. I am trying to develop a web app that connects to a remote server and executes some commands. In trying to connect, i get this error msg: uninitialized constant …

---

## [Getting another dom element value](https://www.ruby-forum.com/t/getting-another-dom-element-value/138745)

<div class="topic-metadata">

**Author:** [@sijo](https://www.ruby-forum.com/u/sijo)\
**Replies:** 1\
**Last updated:** [May 27, 2008, 11:57am UTC](https://www.ruby-forum.com/t/getting-another-dom-element-value/138745 "2008-05-27T11:57:54Z")

</div>

Hi I have a code in view like below…Here I am using Control.modl windows Primary Assignee Group \<%= text\_field "dummy\_service\_desk\_ticket", "dummy\_primary\_assignee\_group", "size" =\> 30, :readon…

---

## [Regexp.escape the href values](https://www.ruby-forum.com/t/regexp-escape-the-href-values/138722)

<div class="topic-metadata">

**Author:** [@vidyagayathri](https://www.ruby-forum.com/u/vidyagayathri)\
**Replies:** 5\
**Last updated:** [May 27, 2008, 11:50am UTC](https://www.ruby-forum.com/t/regexp-escape-the-href-values/138722 "2008-05-27T11:50:50Z")

</div>

Hi All, I want the skip the href values which is inside , while doing rake task. but i am getting out put like this. my text = rails Rails is the keyword, but if already got linked, it should not link again. but i…

---

## [Flash player](https://www.ruby-forum.com/t/flash-player/138741)

<div class="topic-metadata">

**Author:** [@kisrti](https://www.ruby-forum.com/u/kisrti)\
**Replies:** 0\
**Last updated:** [May 27, 2008, 11:31am UTC](https://www.ruby-forum.com/t/flash-player/138741 "2008-05-27T11:31:22Z")

</div>

Hello all, Can anybody tell me how can i play flash player in my Ruby code? Is there any plugin or gem for that. I have tried this but it’s note working. Let me knoe if anybody has done this. Thanks and regards

---

## [Ferret](https://www.ruby-forum.com/t/ferret/138738)

<div class="topic-metadata">

**Author:** [@gaurav\_dua123](https://www.ruby-forum.com/u/gaurav_dua123)\
**Replies:** 2\
**Last updated:** [May 27, 2008, 11:14am UTC](https://www.ruby-forum.com/t/ferret/138738 "2008-05-27T11:14:12Z")

</div>

Can anyone help me from where i will install ferret.

---

## [Generating file for download from controller method on demand](https://www.ruby-forum.com/t/generating-file-for-download-from-controller-method-on-demand/138735)

<div class="topic-metadata">

**Author:** [@PaweSSSSSK](https://www.ruby-forum.com/u/PaweSSSSSK)\
**Replies:** 1\
**Last updated:** [May 27, 2008, 10:54am UTC](https://www.ruby-forum.com/t/generating-file-for-download-from-controller-method-on-demand/138735 "2008-05-27T10:54:13Z")

</div>

Hello I’d like to implement in my app functionality of generating text files for download (like excel files etc.) generated on demand (user clicks “download a copy” and rails app should generate it and let user downl…

---

## [Syntax highlighting for .erb files](https://www.ruby-forum.com/t/syntax-highlighting-for-erb-files/138736)

<div class="topic-metadata">

**Author:** [@lostwarrior](https://www.ruby-forum.com/u/lostwarrior)\
**Replies:** 1\
**Last updated:** [May 27, 2008, 10:47am UTC](https://www.ruby-forum.com/t/syntax-highlighting-for-erb-files/138736 "2008-05-27T10:47:10Z")

</div>

hi i am using radrails for ruby on rails development.I am creating html.erb for my application.i have noticed syntax is not highlighting for html.erb

---

## [Distributed RGL for Multiple mongrels](https://www.ruby-forum.com/t/distributed-rgl-for-multiple-mongrels/138721)

<div class="topic-metadata">

**Author:** [@sgudibanda](https://www.ruby-forum.com/u/sgudibanda)\
**Replies:** 0\
**Last updated:** [May 27, 2008, 8:23am UTC](https://www.ruby-forum.com/t/distributed-rgl-for-multiple-mongrels/138721 "2008-05-27T08:23:14Z")

</div>

Hi I am using RGL library to create a graph which i use in my app. Graph is built for once at startup and is updated at times based on actions that enforce add\_edge/remove edge. I need to traverse this graph for spe…

---

## [Retrieving Mutliple Records using find\_by\_\*](https://www.ruby-forum.com/t/retrieving-mutliple-records-using-find-by/138425)

<div class="topic-metadata">

**Author:** [@mahadewa](https://www.ruby-forum.com/u/mahadewa)\
**Replies:** 9\
**Last updated:** [May 27, 2008, 7:39am UTC](https://www.ruby-forum.com/t/retrieving-mutliple-records-using-find-by/138425 "2008-05-27T07:39:18Z")

</div>

I was hoping that AR’s find\_by\_\* magic methods would help me retrieve multiple items somewhat like the following: names\_to\_find = \[‘Larry’, ‘Moe’, ‘Curly’\] found\_people = Person.find\_by\_name(names\_to\_find) Is there a…

---

## [How to find Date and Time difference in controller?](https://www.ruby-forum.com/t/how-to-find-date-and-time-difference-in-controller/138718)

<div class="topic-metadata">

**Author:** [@ratnavel](https://www.ruby-forum.com/u/ratnavel)\
**Replies:** 0\
**Last updated:** [May 27, 2008, 6:58am UTC](https://www.ruby-forum.com/t/how-to-find-date-and-time-difference-in-controller/138718 "2008-05-27T06:58:12Z")

</div>

Hi, I need a method similar to “distance\_of\_time\_in\_words\_to\_now” to be used in the controller. “distance\_of\_time\_in\_words\_to\_now” methods work only in view. Thanks, Ratnavel.

---

## [Looking for Open Source Rails 2.0 apps](https://www.ruby-forum.com/t/looking-for-open-source-rails-2-0-apps/138719)

<div class="topic-metadata">

**Author:** [@iceburgh](https://www.ruby-forum.com/u/iceburgh)\
**Replies:** 0\
**Last updated:** [May 27, 2008, 6:54am UTC](https://www.ruby-forum.com/t/looking-for-open-source-rails-2-0-apps/138719 "2008-05-27T06:54:47Z")

</div>

I’m looking for Open Source Rails 2.0 apps to use as “targets” for a mechanized documentation system. The “winners” will be used to demonstrate how snazzy my documentation system is, so I’ll be trying Really Hard to …

---

## [Facebooker behind firewall](https://www.ruby-forum.com/t/facebooker-behind-firewall/138710)

<div class="topic-metadata">

**Author:** [@naus](https://www.ruby-forum.com/u/naus)\
**Replies:** 0\
**Last updated:** [May 27, 2008, 4:05am UTC](https://www.ruby-forum.com/t/facebooker-behind-firewall/138710 "2008-05-27T04:05:36Z")

</div>

Hi, I’m trying to set up facebooker on local computer and as soon as I add ensure\_authenticated\_to\_facebook to my controller I get connection errors. After inserting some debugging code I figured it tries to connect t…

---

## [Another test question](https://www.ruby-forum.com/t/another-test-question/138607)

<div class="topic-metadata">

**Author:** [@craigrails](https://www.ruby-forum.com/u/craigrails)\
**Replies:** 17\
**Last updated:** [May 27, 2008, 2:57am UTC](https://www.ruby-forum.com/t/another-test-question/138607 "2008-05-27T02:57:11Z")

</div>

fairly simple actually. CaseManager has\_many :clients Client belongs\_to :case\_manager test/unit/case\_manager.rb fixtures :case\_managers def setup @case\_manager = CaseManager.find(7) end Replace this with y…

---

## [Finding about installed restful\_authentication version](https://www.ruby-forum.com/t/finding-about-installed-restful-authentication-version/138611)

<div class="topic-metadata">

**Author:** [@fipa](https://www.ruby-forum.com/u/fipa)\
**Replies:** 3\
**Last updated:** [May 27, 2008, 2:02am UTC](https://www.ruby-forum.com/t/finding-about-installed-restful-authentication-version/138611 "2008-05-27T02:02:12Z")

</div>

Hi, I am using restful\_authentication in one of my Rails app, the problem is I can’t find anywhere what is the current version of my plugin. I didn’t use subversion to get the plugin I simply downloaded it and install…

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

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