[Rails] Inserting records using REST

2009-11-05 Thread Raju Aralikatti
HI All, I have a situation to insert records from table of one database to a table of another database. Previously I did it using the following code in the script. establish_connection File.open( #{RAILS_ROOT}/config/database.yml ) and change the settings of database.yml to connect to the

[Rails] Re: File not uploading properly

2009-11-03 Thread Raju Aralikatti
Thanks for your help, Its working fine now. I used attachment_fu plugin. Thanks, Raju -- 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

[Rails] File not uploading properly

2009-11-02 Thread Raju Aralikatti
Hi all, I am using the following code to upload a file. views: %= file_field upload, 'file' ,:size= '30' % controller: file_path= #{RAILS_ROOT}/public/email_attachments/#{params[:upload][:file].original_filename} file = File.new(File.join(file_path), wb) file.write(params['file_' +

[Rails] Re: File not uploading properly

2009-11-02 Thread Raju Aralikatti
Thanks a lot for your reply, I have used multiple file upload here is the view part. %= file_field upload, 'file' ,:size= '30', :style= 'color:red;'%br / Attached Files input type='hidden' name='file_nos' id='file_counter' div id=files_list style='display:none;' class='files_list_class'

[Rails] Re: migrate rails project from 1.1.6 to 2.2.2

2009-09-04 Thread Raju Aralikatti
Thanks a lot for your replies, I figured out the problem with form_remote_tag Please go through this link http://mentalized.net/journal/2007/03/13/rails_20_deprecations/ Thanks regards, Raju -- Posted via http://www.ruby-forum.com/. --~--~-~--~~~---~--~~ You

[Rails] Re: migrate rails project from 1.1.6 to 2.2.2

2009-09-03 Thread Raju Aralikatti
thanks for your reply, when I run the rake task $ rake rails:update . My default javascript files ie 1. prototype.js 2. controls.js 3. effects.js 4. dragdrop.js Have changed, can I use the new version of these files, is there anything depreciated compared to the older version. Thanks in

[Rails] Re: migrate rails project from 1.1.6 to 2.2.2

2009-09-03 Thread Raju Aralikatti
While migrating rails project from 1.1.6 to 2.2.2, I am facing the following problems 1. how to use acts_as_tree in 2.2.2, I am getting an error, r...@raju-desktop:~/radrails_workspace/st$ ruby script/about /usr/lib/ruby/gems/1.8/gems/activerecord-2.2.2/lib/active_record/base.rb:1833:in

[Rails] Re: migrate rails project from 1.1.6 to 2.2.2

2009-09-03 Thread Raju Aralikatti
Thanks for your reply Nicholas, Now the only problem I am facing in my application is form_remote_tag How to use form_remote_tag in 2.2.2 I am trying to use it in this way in 2.2.2 %= form_remote_tag({:url = {:controller = 'some_controller', :action =

[Rails] Re: migrate rails project from 1.1.6 to 2.2.2

2009-09-03 Thread Raju Aralikatti
1. acts_as_tree and prototype are working fine. I am getting the following error when i use form_remote_tag in rails 2.2.2 compile error /home/raju/radrails_workspace/st/app/views/admin/predictive_text/_predictive_search.rhtml:19: syntax error, unexpected ')' }) do

[Rails] Re: migrate rails project from 1.1.6 to 2.2.2

2009-09-02 Thread Raju Aralikatti
I did the following. 1. I changed the rails version to 2.2.2 in environment.rb - RAILS_GEM_VERSION = '2.2.2' unless defined? RAILS_GEM_VERSION 2. from project path I ran a rake task $ rake rails:update 3. when i run $ ruby script/about. I get the following output. Please help me. What next

[Rails] Re: migrate rails project from 1.1.6 to 2.2.2

2009-09-02 Thread Raju Aralikatti
Thank you Marnen I am following the same steps. I am directly upgrading to rails 2.2.2 -- 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

[Rails] zip file not downloading properly in IE

2008-11-30 Thread Raju Aralikatti
hi, Here is my code. %require 'rubygems' require 'zip/zipfilesystem' content = content += [InternetShortcut]\n content += URL=http://www.mysite.com/; content += \nIconFile=http://www.mysite.com/favicon.ico\n;

[Rails] Error installing gem

2008-10-25 Thread Raju Aralikatti
Hi, I am getting the following error while installing the gems.. /usr/local/lib/site_ruby/1.8/rubygems.rb:272:in `initialize': wrong number of arguments (1 for 0) (ArgumentError) [EMAIL PROTECTED]:/home/raju/workspace# sudo gem update --system /usr/local/lib/site_ruby/1.8/rubygems.rb:272:in

[Rails] migrate my rails app from v=1.1.6 to v=2.0.1

2008-09-12 Thread Raju Aralikatti
hi all, We have a very big application, We started coding in rails 1.1.6, Now we want to migrate our rails application from the older 1.1.6 version to the latest released version, Can anyone please give me instructions in doing so, is this migration feasible or not, Please tell me disadvantages