[Rails] Re: could not find [gem] locally or in a repository

2008-11-17 Thread Remco Swoany
Shrikant Lokhande wrote: Actually Gem installation need enough memory on your server/system and Bandwidth. or if it is not just download that gem and install specific. gem install rails-2.0.2.gem, Pls check: i have install json like this.

[Rails] Re: Models, find not from database??? really need help :(

2008-11-17 Thread abusiek
On Nov 17, 8:43 am, Daniel Bush [EMAIL PROTECTED] wrote: On Nov 17, 5:45 pm, abusiek [EMAIL PROTECTED] wrote: Hi! I'm struggling with this for a while and i'm new to rails so it's quite frustrating ;) I need to create new model object based on old one with only few changes. I

[Rails] Re: could not find [gem] locally or in a repository

2008-11-17 Thread Abhishek shukla
@remco first check your internet connection and firewall is it working and configured properly or not. Coz the error ERROR: could not find json-1.1.3.gem locally or in a repository it can because of internet connectivity And yes if you are on windows then defiantly you have to do N

[Rails] can't convert String into Integer error on updating

2008-11-17 Thread Raji Mani
% form_for (:contact,:url={:controller='contact',:action = 'update',:id = @contact},:html= {:onSubmit = 'return validate()', :id = 'savecontact'} ) do -% . . . . table cellpadding=4 cellspacing=0 border=1 width=100% class=details tr th colspan=4 align=left bgcolor=#797ba8strongfont

[Rails] Passing an array List of Object

2008-11-17 Thread [EMAIL PROTECTED]
Hi friends, I'm trying to pass an Array list of Objects that I have captured on the fly after querying a web service. I have the array list available with me. Now, the issue that I'm facing is that I would want to pass the Array List of objects to another action defined in my controller.

[Rails] heroku invitaion

2008-11-17 Thread sepehr
could someone send me an heroku invitaion? sepehr.online [at] gmail.com thanks in advance --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Ruby on Rails: Talk group. To post to this group, send email to

[Rails] How could I uninstall the build-in gems in Leopard

2008-11-17 Thread [EMAIL PROTECTED]
I am a newbie on the Mac and ROR. I am trying to install the rails on my Leopard today and get its done. But I found for many of the gems, there are tow versions installed on my machine. There is a lower version installed at /System/Library/Frameworks/Ruby.framework/

[Rails] Developed my personal website in Rails.

2008-11-17 Thread Arunkumar B
Hi Friends, I wanted to take this opportunity to share with you some exciting news! I developed my personal website in Ruby on Rails. Thanks to mephisto URL: http://www.arunkarthick.info Enjoy browsing my website and let me know your feedback in contact page. -- With regards, Arunkumar B.

[Rails] Re: How could I uninstall the build-in gems in Leopard

2008-11-17 Thread Frederick Cheung
On Nov 17, 8:46 am, [EMAIL PROTECTED] [EMAIL PROTECTED] wrote: I am wondering how could I uninstall the old version of these gems? And another question is that I checked the rake file executed which is /usr/bin/rake I didn't find any information or path set there that told the console

[Rails] Re: migration with data

2008-11-17 Thread Sijo Kg
Hi Still I could not solve this problem Sijo -- Posted via http://www.ruby-forum.com/. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Ruby on Rails: Talk group. To post to this group, send email to

[Rails] Re: migration with data

2008-11-17 Thread Frederick Cheung
On 14 Nov 2008, at 04:17, Sijo Kg wrote: Hi I am using postgres and have two migration files like 001_create_categories.rb as class CreateCategories ActiveRecord::Migration def self.up create_table :categories do |t| t.column :name, :string, :limit=80 end end def

[Rails] Re: ERROR: could not find gem rmagick locally or in a repository

2008-11-17 Thread Frederick Cheung
On 17 Nov 2008, at 07:20, Adam Meyer wrote: Hi, I'm trying to install the RMagick 2.7.1 (ImageMagick 6.4.5-3) Win32 Installation got here http://rubyforge.org/frs/?group_id=12a … e_id=27880 I'm following the steps but can't find the gem rmagick locally. I exctracted the zip to

[Rails] Re: migration with data

2008-11-17 Thread Sijo Kg
Hi Thanks for your reply Sijo -- Posted via http://www.ruby-forum.com/. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Ruby on Rails: Talk group. To post to this group, send email to

[Rails] Re: MySQL Schema Error

2008-11-17 Thread Derder Ga
Afrasyab Bashir wrote: Just to add, sadly enough the solution I wrote was true only for MySQL version 5.0.6+ :( 'cos on MySQL 6.0 it's still a problem. On Jul 2, 10:42�am, Matthew Rudy Jacobs [EMAIL PROTECTED] By now, MySQL 6.0.7 and Rails 2.1.2 still have the problem. Mysql::Error:

[Rails] Re: could not find [gem] locally or in a repository

2008-11-17 Thread Frederick Cheung
On 17 Nov 2008, at 08:03, Remco Swoany wrote: i just tried gem install json-1.1.3.gem but again..the error- message: ERROR: could not find json-1.1.3.gem locally or in a repository That will only work if you have a file called json-1.1.3.gem sitting right there. To install over the

[Rails] Re: Models, find not from database??? really need help :(

2008-11-17 Thread Daniel Bush
On Nov 17, 7:37 pm, abusiek [EMAIL PROTECTED] wrote: On Nov 17, 8:43 am, Daniel Bush [EMAIL PROTECTED] wrote: On Nov 17, 5:45 pm, abusiek [EMAIL PROTECTED] wrote: Hi! I'm struggling with this for a while and i'm new to rails so it's quite frustrating ;) I need to create new

[Rails] Re: ERROR: could not find gem rmagick locally or in a reposi

2008-11-17 Thread Adam Meyer
Frederick Cheung wrote: On 17 Nov 2008, at 07:20, Adam Meyer wrote: exctracted the zip to D:\InstantRails\rMagick and when I run update gem update --system Updating RubyGems Nothing to update That command is just for updating rubygems itself. does gem install rmagick not work ?

[Rails] Re: ERROR: could not find gem rmagick locally or in a reposi

2008-11-17 Thread Frederick Cheung
On 17 Nov 2008, at 12:16, Adam Meyer wrote: If I type in gem install rmagick-win32 it says ERROR: could not find gem rmagick-win32 locally or in a repository I know that I need the windows version. I already downloaded it, but I don't know where to put the gem file to make ruby

[Rails] Re: can't convert String into Integer error on updating

2008-11-17 Thread Daniel Bush
Hi, Just a guess... On Nov 17, 7:57 pm, Raji Mani [EMAIL PROTECTED] wrote: % form_for (:contact,:url={:controller='contact',:action = 'update',:id = @contact},:html= {:onSubmit = 'return validate()', :id = 'savecontact'} ) do -% . . . . table cellpadding=4 cellspacing=0 border=1

[Rails] Strange behaviour

2008-11-17 Thread sigvei
I have the following relationships: Document :has_many Proposals :has_many ProposalVersions. This fails: Document.first.proposals.first.proposal_versions.size = 0 But this works: Proposal.find(1).proposal_versions.size = 2 Here's the SQL from the first statement: SELECT count(*) AS

[Rails] active_record: wrong number of arguments (1 for 0)

2008-11-17 Thread Joshua Muheim
Hi all I'm trying to deploy an older Rails app to a new hoster. I uploaded everything, specified the db connection data and started the app. Sadly I'm getting the following error: ArgumentError: wrong number of arguments (1 for 0) from

[Rails] Re: ERROR: could not find gem rmagick locally or in a reposi

2008-11-17 Thread Abhishek shukla
download the rmagick + imageMagick from http://rubyforge.org/frs/download.php/46136/RMagick-2.7.1-ImageMagick-6.4.5-3-Q8.zip extract it let say d:\rmagick First install the imageMagick then go to command prompt into the same directory then type d:\rmagickgem install rmagick_file_name.gem Thats

[Rails] Re: Strange behaviour

2008-11-17 Thread sigvei
On 17 Nov, 14:38, Daniel Bush [EMAIL PROTECTED] wrote: On Nov 17, 11:56 pm, sigvei [EMAIL PROTECTED] wrote: I have the following relationships: Document :has_many Proposals :has_many ProposalVersions. This fails: Document.first.proposals.first.proposal_versions.size Do you mean

[Rails] how would you refactor this to make it more DRY

2008-11-17 Thread [EMAIL PROTECTED]
i have your typical nested resource pattern, and at most any resource is one level deep... so for a model PurchaseOrder which is optionally nested under Customer ive worked up this before_filter... but the problem is, i have my parent class name hard coded into the function... so i can either

[Rails] Database Views in Rails 2.2

2008-11-17 Thread [EMAIL PROTECTED]
Hi, we have a problem upgrading from Rails 2.1.2 to Rails 2.2 because of some Database Views (PostgreSQL) we use. rake db:test:clone_structure is copying the necessary Database Views to the test database. But when I run rake test/spec I see the line FATAL: database name_test does not exist

[Rails] how to change the language settings?

2008-11-17 Thread Ravi Katta
Hi, I have integrated the savage beast plugin for forum.Its working fine but error messages(model validation) are displaying in some other language how to change into english? thanks, -- Posted via http://www.ruby-forum.com/. --~--~-~--~~~---~--~~ You

[Rails] Re: Strange behaviour

2008-11-17 Thread Frederick Cheung
On 17 Nov 2008, at 14:19, sigvei wrote: On 17 Nov, 14:38, Daniel Bush [EMAIL PROTECTED] wrote: On Nov 17, 11:56 pm, sigvei [EMAIL PROTECTED] wrote: I have the following relationships: Document :has_many Proposals :has_many ProposalVersions. This fails:

[Rails] Re: Strange behaviour

2008-11-17 Thread Daniel Bush
On Nov 18, 1:19 am, sigvei [EMAIL PROTECTED] wrote: On 17 Nov, 14:38, Daniel Bush [EMAIL PROTECTED] wrote: On Nov 17, 11:56 pm, sigvei [EMAIL PROTECTED] wrote: I have the following relationships: Document :has_many Proposals :has_many ProposalVersions. This fails:

[Rails] Re: how to change the language settings?

2008-11-17 Thread Abhishek shukla
I am not very much sure but u can use some thing like Globalite plugin. Also check what others are saying. regards Abhisehk On Mon, Nov 17, 2008 at 8:00 PM, Ravi Katta [EMAIL PROTECTED] wrote: Hi, I have integrated the savage beast plugin for forum.Its working fine but error

[Rails] Re: Rails Stability

2008-11-17 Thread Bobnation
That would be my first thought is that his ancient setup (in the sense of how fast things move in technology) might be causing more problems and something more modern might help him out. My recommendation for mod_rails stems more from his talk about portability than anything else and I just

[Rails] Weird params from Safari/525.20 on 10.5.3, {user=foo=xbar=y}, {ids = {0=123, 1=456}

2008-11-17 Thread Henrik N
I've seen a bunch of logged exceptions the last few months, where Rails expects array params like { ids = [123, 456] } but gets { ids = { 0 = 123, 1 = 456] } or expects hash params like { user = { foo = x, bar = y } } but gets {user = foo=xbar=y } So what was supposed to be an array (from

[Rails] Re: Rails Stability

2008-11-17 Thread Roland Mai
The textdrive server has rails 1.1.6 and mongrel 1.0.1 .. so yeah, it's a bit out of date. I have set up mod_rails on my own, but it seems that it too has had (or has) stability issues: http://geek.littleredstring.com/15-phusions-mod_rails-not-so-hot-according-to-railsplayground

[Rails] Re: Weird params from Safari/525.20 on 10.5.3, {user=foo=xbar=y}, {ids = {0=123, 1=456}

2008-11-17 Thread Henrik Nyh
On Mon, Nov 17, 2008 at 4:41 PM, Henrik N [EMAIL PROTECTED] wrote: I've seen a bunch of logged exceptions the last few months, where Rails expects array params like { ids = [123, 456] } but gets { ids = { 0 = 123, 1 = 456] } or expects hash params like { user = { foo = x, bar = y } } but

[Rails] Re: Rails Stability

2008-11-17 Thread Jeremy McAnally
Dreamhost are using mod_rails with great success actually. You can deploy with Mongrel, but they much prefer you to use Passenger. Don't let one blog entry from some random guy turn you away. I guarantee I can find just as many entries about the crappy stability of mod_php, ASP.NET or any

[Rails] html frame tag not work

2008-11-17 Thread daociyiyou
I want to make a view containing the framesetframe tag to let the part to accommodate enough info.But the rails does not support the tag.So how do i get a element that has a scroll bar? Thank you. --~--~-~--~~~---~--~~ You received this message because you are

[Rails] Re: html frame tag not work

2008-11-17 Thread Robby Russell
On Mon, Nov 17, 2008 at 7:48 AM, daociyiyou [EMAIL PROTECTED] wrote: I want to make a view containing the framesetframe tag to let the part to accommodate enough info.But the rails does not support the tag.So how do i get a element that has a scroll bar? Thank you. The first and obvious

[Rails] Re: Rails Stability

2008-11-17 Thread Conrad Taylor
On Mon, Nov 17, 2008 at 7:43 AM, Roland Mai [EMAIL PROTECTED] wrote: The textdrive server has rails 1.1.6 and mongrel 1.0.1 .. so yeah, it's a bit out of date. I have set up mod_rails on my own, but it seems that it too has had (or has) stability issues:

[Rails] Re: Rails Stability

2008-11-17 Thread Bobnation
On Nov 17, 9:48 am, Jeremy McAnally [EMAIL PROTECTED] wrote: Dreamhost are using mod_rails with great success actually.  You can deploy with Mongrel, but they much prefer you to use Passenger. Don't let one blog entry from some random guy turn you away.  I guarantee I can find just as many

[Rails] Re: Rails Stability

2008-11-17 Thread Frederick Cheung
On 17 Nov 2008, at 16:09, Bobnation wrote: On Nov 17, 9:48 am, Jeremy McAnally [EMAIL PROTECTED] wrote: Dreamhost are using mod_rails with great success actually. You can deploy with Mongrel, but they much prefer you to use Passenger. Don't let one blog entry from some random guy turn

[Rails] Re: Rails Stability

2008-11-17 Thread Roland Mai
That was a good read thank you. Frederick Cheung wrote: On 17 Nov 2008, at 16:09, Bobnation wrote: Don't let that one blog entry turn you away. Like Jeremy said, a lot of stuff can cause instabilities, including configuration. I would search around for some hosts and see which ones are

[Rails] Can't seem to test http error codes

2008-11-17 Thread davetron5000
in application.rb rescue_from ActiveRecord::RecordNotFound { |e| http_status_code (:missing, e) } def http_status_code(status, exception) @exception = exception respond_to do |format| format.html { render :template = shared/status_# {status.to_s}, :status = status }

[Rails] Got Redbox or Thickbox experience?

2008-11-17 Thread Bill Walton
Greetings! I could use some feedback / assistance from anyone who's used either one of Redbox or Thickbox with Rails. I've got Redbox functioning but 'had' to do some stuff to make it work (e.g., fixing the size of the Redbox window) that's either 1) my ignorance of how Redbox is supposed to

[Rails] Re: Can't seem to test http error codes

2008-11-17 Thread Frederick Cheung
On 17 Nov 2008, at 16:39, davetron5000 wrote: in application.rb rescue_from ActiveRecord::RecordNotFound { |e| http_status_code (:missing, e) } def http_status_code(status, exception) @exception = exception respond_to do |format| format.html { render :template =

[Rails] Re: Rails Stability

2008-11-17 Thread Fernando Perez
Frederick Cheung wrote: On 17 Nov 2008, at 16:09, Bobnation wrote: Don't let that one blog entry turn you away. Like Jeremy said, a lot of stuff can cause instabilities, including configuration. I would search around for some hosts and see which ones are having the greatest luck with

[Rails] Re: Problem With IE 7

2008-11-17 Thread MACA [15C]
Hi, have you tried like this shade.setStyle({ -moz-opacity: .15; filter:alpha(opacity=15); }); I made a semi-transparent div, some days ago, and it worked for me with Internet Explorer 6 and Mozilla Firefox. Hope this help you. Good luck.

[Rails] Limitations Question

2008-11-17 Thread Donald Immel
I'm a college student learning Ruby on Rails. My instructor has given me a good basis for designing web based solutions with RoR and we've looked at Ajax and script.aculos. I've seen posted on various sites about Ruby being great or Ruby being the root of all evil. As a relatively new

[Rails] Re: Can't seem to test http error codes

2008-11-17 Thread davetron5000
The exception handler IS getting called (I put log statements in and they appear in test.log). In previous versions of rails, there seemed to be some sort of magic where a non-200 http response gets turned into a 500 for development, but not production. Is that the case, and if so, how do I

[Rails] super global dummy method for gettext + rails 2.2

2008-11-17 Thread Olaf
Hi, since rails 2.2 doesn't work with gettext anymore I decided to use a gettext dummy method until the gettext team relases a working version for rails 2.2. My application doesn't need any i18n support right now and this way i figured it would be very easy to integrate gettext later. Just setup

[Rails] Re: super global dummy method for gettext + rails 2.2

2008-11-17 Thread Rob Biedenharn
On Nov 17, 2008, at 2:04 PM, Olaf wrote: Hi, since rails 2.2 doesn't work with gettext anymore I decided to use a gettext dummy method until the gettext team relases a working version for rails 2.2. My application doesn't need any i18n support right now and this way i figured it would be

[Rails] backgrounDRB Cygwin?

2008-11-17 Thread Jeff Miller
Hello, I'm trying to use BackgrounDRB on InstantRails v1.7 (Ruby 1.8.6 and Rails 2.1.0) with Windows Server 2003. I know that I can't use BackgrounDRB on a Windows machine because it uses forking - thats why I installed Cygwin. However, when I attempt to start backgrounDRB, it tells me it is

[Rails] Re: super global dummy method for gettext + rails 2.2

2008-11-17 Thread Olaf
Thanks, I tried that, but it doesnt work. I added to the end of enviroment.rb the following code: class Object def _(s) s end end I also tried class ActiveRecord::Base def _(s) s end end But I still get a method missing error for: class Customer ActiveRecord::Base

[Rails] Cookies are not saved

2008-11-17 Thread Adam Meyer
Hi, I'm developing my first RoR application and working first time with cookies on RoR. I create a product object, save it and set the id into the cookie def create @image = Image.new(params[:image]) respond_to do |format| if @image.save @product = Product.new

[Rails] Re: Implementation guidance, please

2008-11-17 Thread RichardOnRails
Hi DL, I thought I posted a reply to your response, but I don't see it on this thread, so let me add it now. I'm (slowly) trying to apply your guidance. I'll probably run into some problems, but I post specific questions if I can't find solution in the half-dozen Rails book I have nor through

[Rails] how to review changes in a new version of a plugin??? what's the best approach???

2008-11-17 Thread Greg Hauptmann
Hi, Background - I'm a few month behind the latest code for a plugin. I use SVN for my RoR project. Question - What's the best/easiest way to review the changes in a more update version of the plugin against my version? Would it be to checkout out the latest version of the plugin to a temp

[Rails] UPS shipping labels in EPL format?

2008-11-17 Thread Jenifer Louie
I'm using the UPS Shipping Tools to generate shipping labels... I'm able to successfully generate the label data (and I'm able to print the labels in GIF format), but I'm wondering how I could save EPL formatted label data, so a thermal printer (UPS Thermal 2844 from Zebra) can use it? I tried

[Rails] Re: How could I uninstall the build-in gems in Leopard

2008-11-17 Thread Brian Hogan
On our setups, we simply use the built-in mac stuff and then update the old versions. gem update --system gem install rails You can safely ignore the old versions without a problem. On Mon, Nov 17, 2008 at 4:04 AM, Frederick Cheung [EMAIL PROTECTED] wrote: On Nov 17, 8:46 am, [EMAIL

[Rails] Re: super global dummy method for gettext + rails 2.2

2008-11-17 Thread Rob Biedenharn
Try adding class ActiveRecord::Base def self._(s) s end end Since _ will be called as a Class method on Customer at that point. -Rob On Nov 17, 2008, at 4:02 PM, Olaf wrote: Thanks, I tried that, but it doesnt work. I added to the end of enviroment.rb the following code:

[Rails] Re: super global dummy method for gettext + rails 2.2

2008-11-17 Thread Olaf
I tried both class ActiveRecord::Base def self._(s) s end end class Object def self._(msg) return msg end end but nothing worked. I also looked at the gettext gem and it looks to me that they just have a module where the _() method is defined and this module is then required

[Rails] InvalidAuthenticityToken when using XML, why?

2008-11-17 Thread comopasta Gr
Hi, I'm making an app where messages can be posted only from mobile phones. The clients that will connect to the app will NOT use a browser but the client is developed using native language, say C++, Java, etc. Users need to be registered to be able to post. On the server I am using

[Rails] Re: super global dummy method for gettext + rails 2.2

2008-11-17 Thread Olaf
Sorry, my fault, I moved the following code to a file called config/initializers/gettext_dummy.rb class Object def self._(msg) return msg end end The problem was that the definition was outside the init block in the enviroment.rb. STUPID! everithing works now! Thanks On 17 Nov.,

[Rails] Re: super global dummy method for gettext + rails 2.2

2008-11-17 Thread Rob Biedenharn
You probably need both: class ActiveRecord::Base def self._(s); s; end end class Object def _(s); s; end end Together! Not one or the other. You might add other class methods as needed. (FYI, I have no idea what gettext does, but this is just Ruby stuff.) -Rob On Nov 17, 2008, at

[Rails] Cross-database joins on has_many associations

2008-11-17 Thread Wes Gamble
All, I'm looking at possibly having to define a has_many relationship across two databases (possibly even two databases on different servers). To be clear, I mean model A lives in database X and it's related to model B that lives in database Y. A has_many B's. It appears that if I want to do

[Rails] Re: super global dummy method for gettext + rails 2.2

2008-11-17 Thread Rob Biedenharn
Glad you figured it out. -Rob On Nov 17, 2008, at 5:44 PM, Olaf wrote: Sorry, my fault, I moved the following code to a file called config/initializers/gettext_dummy.rb class Object def self._(msg) return msg end end The problem was that the definition was outside the init

[Rails] custom format with BufferedLogger?

2008-11-17 Thread Jonathan Rochkind
So Rails2 provides a new BufferedLogger class that is used for logging. The old monkey-patched Logger class is deprecated. It's nice that the new BufferedLogger doesn't do that weird monkey patching thing, making it easier to sub-class for custom behavior and set your sub-class as the logger,

[Rails] Re: Models, find not from database??? really need help :(

2008-11-17 Thread abusiek
On Nov 17, 1:05 pm, Daniel Bush [EMAIL PROTECTED] wrote: On Nov 17, 7:37 pm,abusiek[EMAIL PROTECTED] wrote: On Nov 17, 8:43 am, Daniel Bush [EMAIL PROTECTED] wrote: On Nov 17, 5:45 pm,abusiek[EMAIL PROTECTED] wrote: Hi! I'm struggling with this for a while and i'm new to

[Rails] Session Corruption?

2008-11-17 Thread Nik B
I have a vexing problem where a request is completed and customer information is stored in session (to be deleted on successful checkout). After the request completes, any subsequent action throws a Internal Server Error 500. This is the stack trace: http://pastie.org/317365 Could I be storing

[Rails] Re: Cross-database joins on has_many associations

2008-11-17 Thread Wes Gamble
Some answers... In my particular case, I may not even need to worry about the has_many relationship from A to B. If all I need to take advantage of is the fact that B belongs_to A, _and_ I'm sure that my keys are all consistent, then simply doing belongs_to :a, :foreign_key =

[Rails] Re: Session Corruption?

2008-11-17 Thread Frederick Cheung
On 18 Nov 2008, at 00:21, Nik B wrote: I have a vexing problem where a request is completed and customer information is stored in session (to be deleted on successful checkout). After the request completes, any subsequent action throws a Internal Server Error 500. You're storing soap

[Rails] Re: customize logger messages in Rails2?

2008-11-17 Thread Frederick Cheung
On 18 Nov 2008, at 00:18, Jonathan Rochkind wrote: Yeah, thanks. I found this patch, which adds formatter functionality to BufferedLogger: http://rails.lighthouseapp.com/projects/8994/tickets/1307-bufferedlogger-should-support-message-formatting Using that as a guide, I have created a

[Rails] Re: customize logger messages in Rails2?

2008-11-17 Thread Jonathan Rochkind
Okay, I finally figured out how to get this to work. Leave this here for future list archive searchers, since I had to put together a bunch of pieces. My custom logger, based on this patch:

[Rails] Re: customize logger messages in Rails2?

2008-11-17 Thread Jonathan Rochkind
Argh, this still isn't quite there yet. Now I can't start my app with script/console, which is convenient sometimes. Because in script/console, somehow ActiveSupport hasn't yet been loaded when it loads the environment. So I had to add a require 'active_support' to my environment, and now

[Rails] Querying date format for DB via ActiveRecord?

2008-11-17 Thread Wes Gamble
Is there a way to query the DB connection behind an AR::Base object for the date string format expected by the DB? I'm trying to use quoted_date, however, this returns a formatted timestamp and the column in question is simply a date. Thanks, Wes -- Posted via http://www.ruby-forum.com/.

[Rails] Restful Authentication

2008-11-17 Thread jrm
Hi, I added authentication to an app that already had a Person model. Rather than use the Person class to represent Users I created a User model and stored users in a users table. I now want to clean that up as my People can now also be Users. My initial stab was to just migrate the

[Rails] Rails 2.2rc2: ArgumentError - Anonymous modules have no name to be referenced by...

2008-11-17 Thread jacques
If you convert your Rails 2.1 app to Rails 2.2RC2, you'll see this fancy error message as soon as you start script server: --- ArgumentError Anonymous modules have no name to be referenced by --- Stack trace will lead you to dependencies.rb:572 Solution: Rename your application.rb to

[Rails] Re: Rails 2.2rc2: ArgumentError - Anonymous modules have no name to be referenced by...

2008-11-17 Thread Pratik
This SHOULD not happen for 2.2 RC2 because 2.2 already has a separate branch. And renaming application.rb - application_controller.rb is an edge only change. On Tue, Nov 18, 2008 at 8:16 AM, jacques [EMAIL PROTECTED] wrote: If you convert your Rails 2.1 app to Rails 2.2RC2, you'll see this

[Rails] Difference between include and joins in find?

2008-11-17 Thread boblu
I had real weird problem here. If I use joins in find, both development and production environment give right answers. But, when I use include in find, the development environment goes all right. However, the find method fails in production enviroment. Let me describe this in detail. I have

[Rails] Re: Rails 2.2rc2: ArgumentError - Anonymous modules have no name to be referenced by...

2008-11-17 Thread jacques
Ah, ok. My bad. I grabbed trunk instead of RC2 On Nov 17, 8:38 pm, Pratik [EMAIL PROTECTED] wrote: This SHOULD not happen for 2.2 RC2 because 2.2 already has a separate branch. And renaming application.rb - application_controller.rb is an edge only change. On Tue, Nov 18, 2008 at 8:16 AM,

[Rails] Re: Ruby console problem

2008-11-17 Thread Sal e. Mander
Hubert Łępicki wrote: Hi Lawrence, I am not an expert on Windows, and generally - ruby is painfully slow in this environment, so you should consider switching to Linux or Mac OS if you want to use ruby with comfort in long term, but I think I know what's your problem. Seems to me that

[Rails] Re: Difference between include and joins in find?

2008-11-17 Thread boblu
OK. I figured out that join is actually doing an inner join which filters the rows that don't have association. And include is actually doing an 'outter join' which shows all the rows from tables. But, however, I still can not figure out why that strange SQL statement comes out. Can anyone

[Rails] Re: Limitations Question

2008-11-17 Thread Pau Cor
Shatter Fist wrote: I've seen posted on various sites about Ruby being great or Ruby being the root of all evil. Yes there are lots of people who love Ruby, and lots who criticize it. The most common complaint is that it is slow. The conventional wisdom is that Ruby is in-fact slower than

[Rails] Testing Rake Tasks

2008-11-17 Thread cheeseprophet
I'm somewhat new to RoR and I've found that along with my main RoR development work I've also developed a number of custom rake tasks that do various things. I'd like to be able to write unit tests for these rake tasks and I've done a fair bit of google but I haven't really seen it explained

[Rails] how can I leverage Validation framework for input parameter collection when I don't have/need to persist to database (i.e. no activerecord table) ???

2008-11-17 Thread Greg Hauptmann
Hi, How can I leverage Validation framework for input parameter collection when I don't have/need to persist to database (i.e. no activerecord table) ??? I have a set of parameters I want to collect from a form that will be used as input to a 2nd stage. I want to collect the parameters and use

[Rails] Missing js.erb template

2008-11-17 Thread Valentino Lun
Dear all I am new to web development, and I am working on some simple ajax function and got the following error that may need your expert opinions. Missing template ecpath_app_version/__version_list.js.erb in view path D:/Ruby/test/ssc_1/app/views I know there is no js.erb file in

[Rails] sortable_element trouble

2008-11-17 Thread David Trasbo
I need some reordering functionality so I tried the sortable_element helper. It is giving me trouble though. I have a show view that looks like this (HAML): %ul#items = render :partial = @menu.items = sortable_element :items, :url = { :action = 'inspect_params' }, :complete =