# Rails

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

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

---

## [Should I sleep here?](https://www.ruby-forum.com/t/should-i-sleep-here/160163)

<div class="topic-metadata">

**Author:** [@gavin](https://www.ruby-forum.com/u/gavin)\
**Replies:** 11\
**Last updated:** [February 12, 2009, 7:45pm UTC](https://www.ruby-forum.com/t/should-i-sleep-here/160163 "2009-02-12T19:45:52Z")

</div>

Hi I’m building an app at the moment where specific items can be added to an order and then purchased through paypal. Becuase the items are limited, it’s important to relist them quickly if the order is not completed…

---

## [Trying to make this application RESTy](https://www.ruby-forum.com/t/trying-to-make-this-application-resty/160125)

<div class="topic-metadata">

**Author:** [@anthony](https://www.ruby-forum.com/u/anthony)\
**Replies:** 2\
**Last updated:** [February 12, 2009, 6:37pm UTC](https://www.ruby-forum.com/t/trying-to-make-this-application-resty/160125 "2009-02-12T18:37:46Z")

</div>

Ok, here’s the basic workflow: A user inputs an order for a customer. This consists of several line items of equipment rental. (So, for example, 3 trucks at 7 am, 7:30, and 8am for June 23). (Ok, this part is easy……

---

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

<div class="topic-metadata">

**Author:** [@bingobob](https://www.ruby-forum.com/u/bingobob)\
**Replies:** 2\
**Last updated:** [February 12, 2009, 6:06pm UTC](https://www.ruby-forum.com/t/routes/160155 "2009-02-12T18:06:39Z")

</div>

I’m trying to figure this. in my schools controller i want to do this… implement a create action to create just the review for the School… def create\_review\_for\_a\_school @review = Review.new @school = School.find(par…

---

## [Named\_scope and having?](https://www.ruby-forum.com/t/named-scope-and-having/160161)

<div class="topic-metadata">

**Author:** [@gabriele](https://www.ruby-forum.com/u/gabriele)\
**Replies:** 9\
**Last updated:** [February 12, 2009, 5:14pm UTC](https://www.ruby-forum.com/t/named-scope-and-having/160161 "2009-02-12T17:14:12Z")

</div>

Hi all, is just my fault… or I can’t write an having caluse for a group in a named scope? °\_° i.e. named\_scope :last\_year\_best\_buyers, :joins =\> :invoices, :conditions =\> {“invoices.closed” =\> true, “invoices.issued…

---

## [Acts\_as\_list sort by multiple items](https://www.ruby-forum.com/t/acts-as-list-sort-by-multiple-items/160176)

<div class="topic-metadata">

**Author:** [@tizzod](https://www.ruby-forum.com/u/tizzod)\
**Replies:** 0\
**Last updated:** [February 12, 2009, 3:59pm UTC](https://www.ruby-forum.com/t/acts-as-list-sort-by-multiple-items/160176 "2009-02-12T15:59:28Z")

</div>

I have a Person model and I’m using acts\_as\_list so I can have drag/drop positioning of people. The only thing is, I want to be able to differentiate between male and female, ie. sort males separately from females. …

---

## [ROXML from\_xml not returning an object instance](https://www.ruby-forum.com/t/roxml-from-xml-not-returning-an-object-instance/159350)

<div class="topic-metadata">

**Author:** [@adamfowleruk](https://www.ruby-forum.com/u/adamfowleruk)\
**Replies:** 3\
**Last updated:** [February 12, 2009, 3:22pm UTC](https://www.ruby-forum.com/t/roxml-from-xml-not-returning-an-object-instance/159350 "2009-02-12T15:22:16Z")

</div>

Hello, I have two ActiveRecord classes. One is Route the other is Waypoints. I have constructed an XML representation so I can use AJAX to create a Route with all waypoints in a single create call to RouteController. …

---

## [Common action for all the controllers](https://www.ruby-forum.com/t/common-action-for-all-the-controllers/160167)

<div class="topic-metadata">

**Author:** [@siddick](https://www.ruby-forum.com/u/siddick)\
**Replies:** 5\
**Last updated:** [February 12, 2009, 3:06pm UTC](https://www.ruby-forum.com/t/common-action-for-all-the-controllers/160167 "2009-02-12T15:06:21Z")

</div>

I am writing a small plugin for ruby on Rails. I faced a problem while create a common action for all the controllers. I found a solution for it, But i am not satisfied with the solution. The solution that I got is :…

---

## [Opening file content into a textarea](https://www.ruby-forum.com/t/opening-file-content-into-a-textarea/160143)

<div class="topic-metadata">

**Author:** [@elioncho](https://www.ruby-forum.com/u/elioncho)\
**Replies:** 2\
**Last updated:** [February 12, 2009, 2:36pm UTC](https://www.ruby-forum.com/t/opening-file-content-into-a-textarea/160143 "2009-02-12T14:36:15Z")

</div>

Hello, Can somebody help me on how to open a file and show it on a text area, and be able to edit it and save it again. Thanks,

---

## [Pass variables inside the page](https://www.ruby-forum.com/t/pass-variables-inside-the-page/160165)

<div class="topic-metadata">

**Author:** [@enzor](https://www.ruby-forum.com/u/enzor)\
**Replies:** 7\
**Last updated:** [February 12, 2009, 2:32pm UTC](https://www.ruby-forum.com/t/pass-variables-inside-the-page/160165 "2009-02-12T14:32:44Z")

</div>

Hi! I need to create a combobox which , depending on the selected value, will display different items whithout reloading the page \<%= select(“product”,“choice”, Pricebooks.find(:all).collect { |p| \[p.name,p.id\]}, {:s…

---

## [Bundle\_fu making my app very slow](https://www.ruby-forum.com/t/bundle-fu-making-my-app-very-slow/160144)

<div class="topic-metadata">

**Author:** [@zero0x](https://www.ruby-forum.com/u/zero0x)\
**Replies:** 1\
**Last updated:** [February 12, 2009, 12:36pm UTC](https://www.ruby-forum.com/t/bundle-fu-making-my-app-very-slow/160144 "2009-02-12T12:36:01Z")

</div>

Hi, I tried the bundle\_fu plugin, and as of moving to production, I noticed, that my views render in 70ms without bundle\_fu, and about 1800ms with it! It’s not always 1800 but most of the time. Is this ok? Shouldn’t…

---

## [Re: Refactoring RJS](https://www.ruby-forum.com/t/re-refactoring-rjs/160066)

<div class="topic-metadata">

**Author:** [@fcheung](https://www.ruby-forum.com/u/fcheung)\
**Replies:** 2\
**Last updated:** [February 12, 2009, 12:19pm UTC](https://www.ruby-forum.com/t/re-refactoring-rjs/160066 "2009-02-12T12:19:33Z")

</div>

On 11 Feb 2009, at 10:41, David wrote: \[:appt\_counter\]}’).style.visibility = ‘hidden’; $(‘start\_drop\_#{params\[:day\]}#{params \[:appt\_counter\]}’).style.display = ‘block’; $('start\_drop#{params\[:day\]}\_#{params \[:appt\_…

---

## [WAP in Rails](https://www.ruby-forum.com/t/wap-in-rails/160157)

<div class="topic-metadata">

**Author:** [@king](https://www.ruby-forum.com/u/king)\
**Replies:** 0\
**Last updated:** [February 12, 2009, 12:14pm UTC](https://www.ruby-forum.com/t/wap-in-rails/160157 "2009-02-12T12:14:50Z")

</div>

Hi All, I am linux system admin…currently we have web application in PHP. Considering to have wap version of the same and looking to get it done in rails. Can any one suggest for what it takes to get wap in rails. Al…

---

## [Questions about Sassy, the recurring payment system](https://www.ruby-forum.com/t/questions-about-sassy-the-recurring-payment-system/160158)

<div class="topic-metadata">

**Author:** [@zaczheng](https://www.ruby-forum.com/u/zaczheng)\
**Replies:** 0\
**Last updated:** [February 12, 2009, 12:01pm UTC](https://www.ruby-forum.com/t/questions-about-sassy-the-recurring-payment-system/160158 "2009-02-12T12:01:21Z")

</div>

Hi Alex, I read about your Sassy release on LRUG’s mailing list sometime ago. Now that I need to implement an ecommerce subscription system for a client, I have been delving into your code. I have a few questions if …

---

## [Setting up remote rails](https://www.ruby-forum.com/t/setting-up-remote-rails/160120)

<div class="topic-metadata">

**Author:** [@The\_Dro](https://www.ruby-forum.com/u/The_Dro)\
**Replies:** 4\
**Last updated:** [February 12, 2009, 11:31am UTC](https://www.ruby-forum.com/t/setting-up-remote-rails/160120 "2009-02-12T11:31:23Z")

</div>

I’ve got a remote machine on my network which has Ubuntu as the OS. I run my testserver on it with all my current PHP sites. All I have to type on my main Vista Machine as the URL is “http://testserver” and it takes m…

---

## [File uploading using ajax](https://www.ruby-forum.com/t/file-uploading-using-ajax/157379)

<div class="topic-metadata">

**Author:** [@martin\_mercy2001](https://www.ruby-forum.com/u/martin_mercy2001)\
**Replies:** 4\
**Last updated:** [February 12, 2009, 11:25am UTC](https://www.ruby-forum.com/t/file-uploading-using-ajax/157379 "2009-02-12T11:25:29Z")

</div>

Dear all, I have a doubt, iam not getting the uploaded file when iam uploading using ajax form like, \<% remote\_form\_for(:videos, :url =\> {:controller =\> :videos, :action =\> :add }, :html =\> { :multipart =\> true, :aj…

---

## [NoMethodError](https://www.ruby-forum.com/t/nomethoderror/160151)

<div class="topic-metadata">

**Author:** [@zqj](https://www.ruby-forum.com/u/zqj)\
**Replies:** 1\
**Last updated:** [February 12, 2009, 10:36am UTC](https://www.ruby-forum.com/t/nomethoderror/160151 "2009-02-12T10:36:45Z")

</div>

Help me: NoMethodError in SortsController#destroy NoMethodError RAILS\_ROOT: E:/instantRail-2/rails\_apps/greenAdmin Application Trace | Framework Trace | Full Trace E:/instantRail-2/ruby/lib/ruby/gems/1.8/gems/active…

---

## [Rspec test cannot be passed when render partial in layout](https://www.ruby-forum.com/t/rspec-test-cannot-be-passed-when-render-partial-in-layout/160150)

<div class="topic-metadata">

**Author:** [@zerogy](https://www.ruby-forum.com/u/zerogy)\
**Replies:** 7\
**Last updated:** [February 12, 2009, 10:36am UTC](https://www.ruby-forum.com/t/rspec-test-cannot-be-passed-when-render-partial-in-layout/160150 "2009-02-12T10:36:09Z")

</div>

I have a problem stuck me couples of days, could anyone help me? Thanks very much. The problem is that rspec test cannot be passed when the layout contains :partial, once i removed the :partial, the rspec test passed…

---

## [\[ANN\] Radiant 0.7.0 Intaglio Release](https://www.ruby-forum.com/t/ann-radiant-0-7-0-intaglio-release/159735)

<div class="topic-metadata">

**Author:** [@smc7000](https://www.ruby-forum.com/u/smc7000)\
**Replies:** 8\
**Last updated:** [February 12, 2009, 10:14am UTC](https://www.ruby-forum.com/t/ann-radiant-0-7-0-intaglio-release/159735 "2009-02-12T10:14:26Z")

</div>

Looks like it’s time for another release of Radiant: http://radiantcms.org/download/ Radiant 0.7.0 “Intaglio” culminates six months of refactoring and bug- fixing by a dedicated team of contributors. The major milesto…

---

## [Column not in table (legacy database)](https://www.ruby-forum.com/t/column-not-in-table-legacy-database/160129)

<div class="topic-metadata">

**Author:** [@pete](https://www.ruby-forum.com/u/pete)\
**Replies:** 1\
**Last updated:** [February 12, 2009, 9:54am UTC](https://www.ruby-forum.com/t/column-not-in-table-legacy-database/160129 "2009-02-12T09:54:28Z")

</div>

I have been pushing my way through the issues regarding using legacy database tables and I am making some progress but have run into a couple of challenges. The test application I am working with has an employee maste…

---

## [Form\_remote\_tag comes back before saving really done?](https://www.ruby-forum.com/t/form-remote-tag-comes-back-before-saving-really-done/160145)

<div class="topic-metadata">

**Author:** [@comopasta](https://www.ruby-forum.com/u/comopasta)\
**Replies:** 2\
**Last updated:** [February 12, 2009, 8:52am UTC](https://www.ruby-forum.com/t/form-remote-tag-comes-back-before-saving-really-done/160145 "2009-02-12T08:52:30Z")

</div>

Hi, I am having troubles with a form\_remote\_tag. I have this form: \<% form\_remote\_tag :url =\> { :action =\> ‘create’, :controller =\> ‘invitations’ } do %\> \<%= hidden\_field\_tag ‘invite’, user.id %\> \<%= hidden\_field\_t…

---

## [Class Library for RoR](https://www.ruby-forum.com/t/class-library-for-ror/160141)

<div class="topic-metadata">

**Author:** [@magdyserour](https://www.ruby-forum.com/u/magdyserour)\
**Replies:** 1\
**Last updated:** [February 12, 2009, 8:38am UTC](https://www.ruby-forum.com/t/class-library-for-ror/160141 "2009-02-12T08:38:44Z")

</div>

I just wonder if anyone is aware of the existence of any RoR class library, please provide any information if you do. Many thanks, Mags

---

## [Validates\_presence\_of - only on edit](https://www.ruby-forum.com/t/validates-presence-of-only-on-edit/160103)

<div class="topic-metadata">

**Author:** [@perezda](https://www.ruby-forum.com/u/perezda)\
**Replies:** 3\
**Last updated:** [February 12, 2009, 7:48am UTC](https://www.ruby-forum.com/t/validates-presence-of-only-on-edit/160103 "2009-02-12T07:48:22Z")

</div>

Ok so not sure if this is possible but it would help out a lot if it is. I am trying to put this validation on one of my forms validates\_presence\_of :name, :state however I only need this validation to run when they …

---

## [Ar-extensions-0.8.0 - "ActiveRecord::Extensions::FindToCSV"](https://www.ruby-forum.com/t/ar-extensions-0-8-0-activerecord-findtocsv/160142)

<div class="topic-metadata">

**Author:** [@sanand83](https://www.ruby-forum.com/u/sanand83)\
**Replies:** 1\
**Last updated:** [February 12, 2009, 7:38am UTC](https://www.ruby-forum.com/t/ar-extensions-0-8-0-activerecord-findtocsv/160142 "2009-02-12T07:38:10Z")

</div>

Hi All, Facing some problem with the new version of the ar-extensions-0.8.0. With the previous version of this ar-extensions-0.7.0, I was able to use the “include ActiveRecord::Extensions::FindToCSV” without any prob…

---

## [How to prevent users from looking at other user's data](https://www.ruby-forum.com/t/how-to-prevent-users-from-looking-at-other-users-data/160105)

<div class="topic-metadata">

**Author:** [@Gerwin](https://www.ruby-forum.com/u/Gerwin)\
**Replies:** 2\
**Last updated:** [February 12, 2009, 2:31am UTC](https://www.ruby-forum.com/t/how-to-prevent-users-from-looking-at-other-users-data/160105 "2009-02-12T02:31:10Z")

</div>

Say I have Users. A user can login and create e.g. Houses…and Houses can contain People …etc. How do I prevent another logged in user from accessing another user’s House (e.g. http://test.com/houses/1 → where id=1 do…

---

## [An error of Missing template](https://www.ruby-forum.com/t/an-error-of-missing-template/156745)

<div class="topic-metadata">

**Author:** [@youhaodeyi](https://www.ruby-forum.com/u/youhaodeyi)\
**Replies:** 1\
**Last updated:** [February 11, 2009, 10:35pm UTC](https://www.ruby-forum.com/t/an-error-of-missing-template/156745 "2009-02-11T22:35:28Z")

</div>

I use observe\_form to monitor a form, whenever a field changed in this form, an (Missing template builder/update\_make\_view\_info.js.erb…) error will be thrown. I don’t want to use js format. I want to use html.erb form…

---

## [ThroughAssociations](https://www.ruby-forum.com/t/throughassociations/160086)

<div class="topic-metadata">

**Author:** [@giga](https://www.ruby-forum.com/u/giga)\
**Replies:** 6\
**Last updated:** [February 11, 2009, 9:35pm UTC](https://www.ruby-forum.com/t/throughassociations/160086 "2009-02-11T21:35:42Z")

</div>

There is example: http://wiki.rubyonrails.org/rails/pages/ThroughAssociations Example Catalogue has\_many :catalogue\_items CatalogueItems belongs\_to :catalogue; belongs\_to :product Product has\_many :catalogue\_items S…

---

## [ActionView URL helper problem](https://www.ruby-forum.com/t/actionview-url-helper-problem/160106)

<div class="topic-metadata">

**Author:** [@byrnejb](https://www.ruby-forum.com/u/byrnejb)\
**Replies:** 1\
**Last updated:** [February 11, 2009, 9:19pm UTC](https://www.ruby-forum.com/t/actionview-url-helper-problem/160106 "2009-02-11T21:19:31Z")

</div>

Rails 2.2.2 In the API it says this: Classes and ids for CSS are easy to produce: link\_to “Articles”, articles\_path, :id =\> “news”, :class =\> “article” =\> Articles In my code I do this: \<%= link\_to ‘List All Vendo…

---

## [Legacy Schemas dynamic find](https://www.ruby-forum.com/t/legacy-schemas-dynamic-find/160101)

<div class="topic-metadata">

**Author:** [@rambor](https://www.ruby-forum.com/u/rambor)\
**Replies:** 0\
**Last updated:** [February 11, 2009, 8:35pm UTC](https://www.ruby-forum.com/t/legacy-schemas-dynamic-find/160101 "2009-02-11T20:35:50Z")

</div>

Hello, I’m trying to put a rails face on a legacy database. It is an old Sybase 11 database installation. I’ve gotten an ODBC connection working that uses unixODBC and FreeTDS to work. I’m also using the activerecord…

---

## [Importing User Libraries into Rails](https://www.ruby-forum.com/t/importing-user-libraries-into-rails/160097)

<div class="topic-metadata">

**Author:** [@Shak](https://www.ruby-forum.com/u/Shak)\
**Replies:** 0\
**Last updated:** [February 11, 2009, 8:07pm UTC](https://www.ruby-forum.com/t/importing-user-libraries-into-rails/160097 "2009-02-11T20:07:53Z")

</div>

Hi all, I’m using Netbeans 6.5 to develop a Rails application. I have already developed a small library to assist me in the app. It is in another project/directory. What is the best way to load this library in Rails? …

---

## [Mongrel logging config](https://www.ruby-forum.com/t/mongrel-logging-config/160096)

<div class="topic-metadata">

**Author:** [@roobnoob](https://www.ruby-forum.com/u/roobnoob)\
**Replies:** 0\
**Last updated:** [February 11, 2009, 7:55pm UTC](https://www.ruby-forum.com/t/mongrel-logging-config/160096 "2009-02-11T19:55:35Z")

</div>

Hi, how do i enable http request logging in mongrel, when there’s nothing sitting in front of mongrel (ie, all http requests hit mongrel directly) ?? I’m using mongrel\_rails to start up mongrel (a cluster of 1). The p…

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

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