# Rails

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

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

---

## [Automated XML sitemap](https://www.ruby-forum.com/t/automated-xml-sitemap/189093)

<div class="topic-metadata">

**Author:** [@deepti](https://www.ruby-forum.com/u/deepti)\
**Replies:** 3\
**Last updated:** [July 1, 2010, 7:33am UTC](https://www.ruby-forum.com/t/automated-xml-sitemap/189093 "2010-07-01T07:33:43Z")

</div>

Hi, I am looking for a solution to generate ‘Automated sitemap.xml’ in ROR. Is there any gem available for the same or if there is any other solution…?? I was earlier using site map generator but that doesn’t fulfill…

---

## [Need help with validation, toggle, checkbox etc](https://www.ruby-forum.com/t/need-help-with-validation-toggle-checkbox-etc/190934)

<div class="topic-metadata">

**Author:** [@tomtt](https://www.ruby-forum.com/u/tomtt)\
**Replies:** 2\
**Last updated:** [July 1, 2010, 3:00am UTC](https://www.ruby-forum.com/t/need-help-with-validation-toggle-checkbox-etc/190934 "2010-07-01T03:00:23Z")

</div>

hi, im gettin lost with the subject. need some pointers: Usermodel: validates\_presence\_of :companyname, :if =\> :is\_company? \<%= f.label "Are u representing a company?" %\> \<%= f.check\_box :is\_company, :onclic…

---

## [Open-source project needs test suite help](https://www.ruby-forum.com/t/open-source-project-needs-test-suite-help/190933)

<div class="topic-metadata">

**Author:** [@AdamPHX](https://www.ruby-forum.com/u/AdamPHX)\
**Replies:** 0\
**Last updated:** [July 1, 2010, 2:01am UTC](https://www.ruby-forum.com/t/open-source-project-needs-test-suite-help/190933 "2010-07-01T02:01:52Z")

</div>

Hi everyone: There’s a great opportunity for Rails developers to contribute to a community project for light rail neighborhoods. CityCircles won a Knight Foundation grant in 2009 to create new ways for people to shar…

---

## [Paginate\_by\_sql and Rails 3.0.0beta4](https://www.ruby-forum.com/t/paginate-by-sql-and-rails-3-0-0beta4/190918)

<div class="topic-metadata">

**Author:** [@Obelix](https://www.ruby-forum.com/u/Obelix)\
**Replies:** 1\
**Last updated:** [July 1, 2010, 1:50am UTC](https://www.ruby-forum.com/t/paginate-by-sql-and-rails-3-0-0beta4/190918 "2010-07-01T01:50:09Z")

</div>

I am trying to port an existing rails app running rails 2.3.8 to 3.0.0beta4 I use this paginate\_by\_sql hack module ActiveRecord class Base def self.find\_by\_sql\_with\_limit(sql, offset, limit) sql = sanitize\_sql(sql) …

---

## [Rails3.0.0Beta4 setting session store to database](https://www.ruby-forum.com/t/rails3-0-0beta4-setting-session-store-to-database/190929)

<div class="topic-metadata">

**Author:** [@Obelix](https://www.ruby-forum.com/u/Obelix)\
**Replies:** 0\
**Last updated:** [July 1, 2010, 1:50am UTC](https://www.ruby-forum.com/t/rails3-0-0beta4-setting-session-store-to-database/190929 "2010-07-01T01:50:09Z")

</div>

I am porting a Rails 2.3.8 app to Rails 3.0.0Beta4. I can’t get the session to be written to the database instead of cookies. I do the following in config/environments/development.rb config.session\_store(:active\_recor…

---

## [Drb problem? ringy-dingy won't answer](https://www.ruby-forum.com/t/drb-problem-ringy-dingy-wont-answer/226070)

<div class="topic-metadata">

**Author:** [@patrick\_nicholas](https://www.ruby-forum.com/u/patrick_nicholas)\
**Replies:** 0\
**Last updated:** [July 1, 2010, 1:38am UTC](https://www.ruby-forum.com/t/drb-problem-ringy-dingy-wont-answer/226070 "2010-07-01T01:38:27Z")

</div>

The following code works fine as long as I don’t try to run it through the distributed server. It doesn’t get there… It runs fine out of delayed\_job, runs fine if called directly. But if ‘distrib’ is true (the defaul…

---

## [Rake TestTask problem with t.options](https://www.ruby-forum.com/t/rake-testtask-problem-with-t-options/190925)

<div class="topic-metadata">

**Author:** [@Jedrin](https://www.ruby-forum.com/u/Jedrin)\
**Replies:** 0\
**Last updated:** [June 30, 2010, 11:43pm UTC](https://www.ruby-forum.com/t/rake-testtask-problem-with-t-options/190925 "2010-06-30T23:43:10Z")

</div>

I am trying to understand some rake stuff better … I have a test that works fine if I do: “ruby test/integration/tcp\_test.rb -n test\_job\_create” but if I try to do it in a rake file like below, it errors out. It seem…

---

## [CAN'T FIND without an ID](https://www.ruby-forum.com/t/cant-find-without-an-id/186303)

<div class="topic-metadata">

**Author:** [@davidz101](https://www.ruby-forum.com/u/davidz101)\
**Replies:** 16\
**Last updated:** [June 30, 2010, 9:47pm UTC](https://www.ruby-forum.com/t/cant-find-without-an-id/186303 "2010-06-30T21:47:50Z")

</div>

I’m getting this error- ActiveRecord::RecordNotFound in PagesController#create Couldn’t find Course without an ID Btw, the pages belongs to courses, and the courses has many pages Now, in my pages controller, for my…

---

## [PKI authentication? Webrat, Selenium, restful-auth...?](https://www.ruby-forum.com/t/pki-authentication-webrat-selenium-restful-auth/190872)

<div class="topic-metadata">

**Author:** [@trevoke](https://www.ruby-forum.com/u/trevoke)\
**Replies:** 2\
**Last updated:** [June 30, 2010, 9:30pm UTC](https://www.ruby-forum.com/t/pki-authentication-webrat-selenium-restful-auth/190872 "2010-06-30T21:30:45Z")

</div>

Hi, We are trying to fix a test suite to check an app which uses PKI authentication. Is there something out there which could make our lives easier? Webrat and Selenium don’t seem to support this right now. Thanks.

---

## [FTP: which FTP is best for Ubuntu to upload rails project](https://www.ruby-forum.com/t/ftp-which-ftp-is-best-for-ubuntu-to-upload-rails-project/190883)

<div class="topic-metadata">

**Author:** [@aliibrahim](https://www.ruby-forum.com/u/aliibrahim)\
**Replies:** 3\
**Last updated:** [June 30, 2010, 8:46pm UTC](https://www.ruby-forum.com/t/ftp-which-ftp-is-best-for-ubuntu-to-upload-rails-project/190883 "2010-06-30T20:46:22Z")

</div>

I am trying to upload the constants to my shared server but built in FTP in Ubuntu is not working

---

## [Cannot connect in jruby rails for newbie using jruby-1.5.0 final and rails 2.3.3](https://www.ruby-forum.com/t/cannot-connect-in-jruby-rails-for-newbie-using-jruby-1-5-0-final-and-rails-2-3-3/190921)

<div class="topic-metadata">

**Author:** [@davidjrice](https://www.ruby-forum.com/u/davidjrice)\
**Replies:** 1\
**Last updated:** [June 30, 2010, 8:37pm UTC](https://www.ruby-forum.com/t/cannot-connect-in-jruby-rails-for-newbie-using-jruby-1-5-0-final-and-rails-2-3-3/190921 "2010-06-30T20:37:18Z")

</div>

can’t connect nor db:migrate using jruby-1.5.0(final) and rails 2.3.3 on a windows XP machine here is my database.yml: development: adapter: jdbc driver: oracle.jdbc.driver.OracleDriver url: jdbc:oracle:thin:@local…

---

## [Send\_data](https://www.ruby-forum.com/t/send-data/190817)

<div class="topic-metadata">

**Author:** [@mamadoutoure](https://www.ruby-forum.com/u/mamadoutoure)\
**Replies:** 13\
**Last updated:** [June 30, 2010, 7:37pm UTC](https://www.ruby-forum.com/t/send-data/190817 "2010-06-30T19:37:53Z")

</div>

I want to display a pdf on my browser bu using send\_data(File.read(FILE\_PATH + FILE\_NAME), :type =\> ‘application/pdf’,:disposition =\> ‘inline’, :filename =\> FILE\_NAME) But nothing happens. Do you know why ?

---

## [Search plugin/gem recommendation for search with joins](https://www.ruby-forum.com/t/search-plugin-gem-recommendation-for-search-with-joins/190873)

<div class="topic-metadata">

**Author:** [@cmaxvv](https://www.ruby-forum.com/u/cmaxvv)\
**Replies:** 6\
**Last updated:** [June 30, 2010, 7:34pm UTC](https://www.ruby-forum.com/t/search-plugin-gem-recommendation-for-search-with-joins/190873 "2010-06-30T19:34:57Z")

</div>

Hi all. It’s time to choose a search system for a new app i’ve been working on and though i’d crowdsource some wisdom. I’ve used ferret/acts\_as\_ferret before and encountered some problems which make me reluctant to …

---

## [Redirecting old URLs to new permalinked URLs](https://www.ruby-forum.com/t/redirecting-old-urls-to-new-permalinked-urls/190499)

<div class="topic-metadata">

**Author:** [@joe](https://www.ruby-forum.com/u/joe)\
**Replies:** 24\
**Last updated:** [June 30, 2010, 7:28pm UTC](https://www.ruby-forum.com/t/redirecting-old-urls-to-new-permalinked-urls/190499 "2010-06-30T19:28:56Z")

</div>

Im currently in the process of adding permalinking to my site; at the moment I am simply testing it out in development mode. The problem is that at the moment I have all of these URLs that lead to the same content: h…

---

## [Is it possible...?](https://www.ruby-forum.com/t/is-it-possible/190915)

<div class="topic-metadata">

**Author:** [@anon\_comp](https://www.ruby-forum.com/u/anon_comp)\
**Replies:** 3\
**Last updated:** [June 30, 2010, 6:07pm UTC](https://www.ruby-forum.com/t/is-it-possible/190915 "2010-06-30T18:07:08Z")

</div>

I’ve made a scaffold project that has been edited so that when you create a new task, the show method will run though some ruby code that manipulates the data inputed. I want to make it so that when a user types in th…

---

## [Where to put custom URL parser](https://www.ruby-forum.com/t/where-to-put-custom-url-parser/190916)

<div class="topic-metadata">

**Author:** [@PsiPro](https://www.ruby-forum.com/u/PsiPro)\
**Replies:** 0\
**Last updated:** [June 30, 2010, 5:53pm UTC](https://www.ruby-forum.com/t/where-to-put-custom-url-parser/190916 "2010-06-30T17:53:04Z")

</div>

I’ve written a routine for encoding and decoding custom urls. My route looks like: map.browse ‘items/browse/\*query’, :controller =\> ‘items’, :action =\> ‘browse’ Now the param query is suposed to look something like: …

---

## [App not run when I upload on hosting support RoR](https://www.ruby-forum.com/t/app-not-run-when-i-upload-on-hosting-support-ror/190899)

<div class="topic-metadata">

**Author:** [@vuonghung12a2](https://www.ruby-forum.com/u/vuonghung12a2)\
**Replies:** 1\
**Last updated:** [June 30, 2010, 5:19pm UTC](https://www.ruby-forum.com/t/app-not-run-when-i-upload-on-hosting-support-ror/190899 "2010-06-30T17:19:41Z")

</div>

I have app RoR good running on NetBean with JRuby But, I upload up server to server, it not run. I have ready setup rubygem. Cau you help me? please guide detail with me about work from how to upload code to server …

---

## [Prawn gem: How to create the .pdf from an \*existing\* file](https://www.ruby-forum.com/t/prawn-gem-how-to-create-the-pdf-from-an-existing-file/190903)

<div class="topic-metadata">

**Author:** [@tharrisx](https://www.ruby-forum.com/u/tharrisx)\
**Replies:** 1\
**Last updated:** [June 30, 2010, 5:08pm UTC](https://www.ruby-forum.com/t/prawn-gem-how-to-create-the-pdf-from-an-existing-file/190903 "2010-06-30T17:08:47Z")

</div>

Hi there, Can anybody show me (maybe copy/paste a simple code example) how to create the .pdf file from an existing (.xls) file, using the Prawn gem? Basically, I’d need the command that takes an existing (.xls) file …

---

## [Possible to recover data from log/development.log files?](https://www.ruby-forum.com/t/possible-to-recover-data-from-log-development-log-files/190866)

<div class="topic-metadata">

**Author:** [@arvliet](https://www.ruby-forum.com/u/arvliet)\
**Replies:** 3\
**Last updated:** [June 30, 2010, 4:53pm UTC](https://www.ruby-forum.com/t/possible-to-recover-data-from-log-development-log-files/190866 "2010-06-30T16:53:14Z")

</div>

Hey all. Seems I’ve found a bug in Rails db:migrate - maybe it is, maybe it isn’t. If possible - I’d appreciate some help recovering from it. Apps, OS, etc.: MySQL: Ver 14.12 Distrib 5.0.77, for redhat-linux-gnu…

---

## [Deploy: First Rails App to shared server](https://www.ruby-forum.com/t/deploy-first-rails-app-to-shared-server/190732)

<div class="topic-metadata">

**Author:** [@aliibrahim](https://www.ruby-forum.com/u/aliibrahim)\
**Replies:** 17\
**Last updated:** [June 30, 2010, 4:31pm UTC](https://www.ruby-forum.com/t/deploy-first-rails-app-to-shared-server/190732 "2010-06-30T16:31:04Z")

</div>

I installed ruby: 1.8.7 rails: 2.3.8 gems: 1.3.5 on the Ubuntu with passenger 2.2.15 now i create the first demo application, i create a folder on home “ruby”-\>“demo” than i created a sites-available udo nano /…

---

## [How to get a join query to work?](https://www.ruby-forum.com/t/how-to-get-a-join-query-to-work/190898)

<div class="topic-metadata">

**Author:** [@caiwangqin](https://www.ruby-forum.com/u/caiwangqin)\
**Replies:** 1\
**Last updated:** [June 30, 2010, 4:03pm UTC](https://www.ruby-forum.com/t/how-to-get-a-join-query-to-work/190898 "2010-06-30T16:03:56Z")

</div>

Award.all(:joins =\> “INNER JOIN overall\_rankings ON (overall\_rankings.poem\_id = awards.poem\_id)”) gets the wrong award.overall\_ranking on heroku postgres Poem has\_many :awards has\_one :overall\_ranking Award belon…

---

## [Rails 3 api](https://www.ruby-forum.com/t/rails-3-api/190792)

<div class="topic-metadata">

**Author:** [@victor123789](https://www.ruby-forum.com/u/victor123789)\
**Replies:** 3\
**Last updated:** [June 30, 2010, 3:43pm UTC](https://www.ruby-forum.com/t/rails-3-api/190792 "2010-06-30T15:43:04Z")

</div>

I’m being googledumb and just can’t be sure to find the rails3.0.0.beta API’s… anyone have a link? Also i read somewhere, I think the RVM gerbil told me, that I can generate my own api docs? Any quick hints? Thanks, …

---

## [PDFKIT Gem Example](https://www.ruby-forum.com/t/pdfkit-gem-example/190387)

<div class="topic-metadata">

**Author:** [@railslist](https://www.ruby-forum.com/u/railslist)\
**Replies:** 4\
**Last updated:** [June 30, 2010, 3:10pm UTC](https://www.ruby-forum.com/t/pdfkit-gem-example/190387 "2010-06-30T15:10:52Z")

</div>

Hi Everybody, Can anyone give me a small working example of how to use PDFKIT to convert a view in rails app to pdf file? Any help is much appreciated! Thanks!

---

## [Problem with named routes](https://www.ruby-forum.com/t/problem-with-named-routes/190905)

<div class="topic-metadata">

**Author:** [@kingston](https://www.ruby-forum.com/u/kingston)\
**Replies:** 0\
**Last updated:** [June 30, 2010, 2:05pm UTC](https://www.ruby-forum.com/t/problem-with-named-routes/190905 "2010-06-30T14:05:43Z")

</div>

hello, I am facing a problem in while defining named routes Here is my code in config/routes.rb map.addon ‘/addons’,:controller =\> ‘settings’,:action =\> ‘addons’ map.demonstration ‘/demonstrations’,:controller =\> ‘se…

---

## [Validates\* inside method](https://www.ruby-forum.com/t/validates-inside-method/190900)

<div class="topic-metadata">

**Author:** [@pepe](https://www.ruby-forum.com/u/pepe)\
**Replies:** 0\
**Last updated:** [June 30, 2010, 12:18pm UTC](https://www.ruby-forum.com/t/validates-inside-method/190900 "2010-06-30T12:18:44Z")

</div>

Is there a way of using the ‘validates\*’ methods inside another method? For instance, I need to make sure a field is empty under a certain set of circumstances and contain data under a different set of circumstances. …

---

## [Mongrel is Terminating Automatically](https://www.ruby-forum.com/t/mongrel-is-terminating-automatically/190006)

<div class="topic-metadata">

**Author:** [@sumantacaptain](https://www.ruby-forum.com/u/sumantacaptain)\
**Replies:** 2\
**Last updated:** [June 30, 2010, 11:02am UTC](https://www.ruby-forum.com/t/mongrel-is-terminating-automatically/190006 "2010-06-30T11:02:02Z")

</div>

Dear All, I am facing a problem - when I am hitting http://localhost:3000/login\_c to enter to our system, webrick/mongrel quiting from command prompt. I am getting this error- “” C:\\Obs\>mongrel\_rails start \*\* Start…

---

## [I have problem ....PostgreSQLAdapter::PGconn](https://www.ruby-forum.com/t/i-have-problem-postgresqladapter-pgconn/190892)

<div class="topic-metadata">

**Author:** [@vuonghung12a2](https://www.ruby-forum.com/u/vuonghung12a2)\
**Replies:** 0\
**Last updated:** [June 30, 2010, 8:46am UTC](https://www.ruby-forum.com/t/i-have-problem-postgresqladapter-pgconn/190892 "2010-06-30T08:46:24Z")

</div>

I have a problem when i am creating a rails project using postgresql… uninitialized constant ActiveRecord::ConnectionAdapters::PostgreSQLAdapter::PGconn I have already installed gem postgres-pr. but not start… I usin…

---

## [Referencing a Layout](https://www.ruby-forum.com/t/referencing-a-layout/190881)

<div class="topic-metadata">

**Author:** [@djames](https://www.ruby-forum.com/u/djames)\
**Replies:** 10\
**Last updated:** [June 30, 2010, 6:08am UTC](https://www.ruby-forum.com/t/referencing-a-layout/190881 "2010-06-30T06:08:08Z")

</div>

My understanding is that Rails generally expects layouts to be files and any reference to a layout is a path to the appropriate file. Thus, a layout that is generated at run time and stored only in memory (as a variab…

---

## [OAI-PMH problem with more than one parameter](https://www.ruby-forum.com/t/oai-pmh-problem-with-more-than-one-parameter/181314)

<div class="topic-metadata">

**Author:** [@szymonides](https://www.ruby-forum.com/u/szymonides)\
**Replies:** 6\
**Last updated:** [June 30, 2010, 5:29am UTC](https://www.ruby-forum.com/t/oai-pmh-problem-with-more-than-one-parameter/181314 "2010-06-30T05:29:15Z")

</div>

Hello. I’m trying to make my site work with OAI-PMH (http:// oai.rubyforge.org/). Whilst running the tests on http://re.cs.uct.ac.za/ it seems that it can’t process more than two parameters. For example: http://mysit…

---

## [Activesupport classify truncates](https://www.ruby-forum.com/t/activesupport-classify-truncates/190888)

<div class="topic-metadata">

**Author:** [@Don\_F](https://www.ruby-forum.com/u/Don_F)\
**Replies:** 0\
**Last updated:** [June 30, 2010, 5:02am UTC](https://www.ruby-forum.com/t/activesupport-classify-truncates/190888 "2010-06-30T05:02:44Z")

</div>

Sorry about cross posting, but this is where it really belongs. I tried to use “my\_class”.classify and got MyClas as a result. Tried others that ended in ‘ss’ and got the same results. Tried other endings and they wo…

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

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