Ruby on Rails » News
Record Remote IP AddressThu, 02 Sep 2010 21:08:09 UT
I've seen several examples online about people wanting to record the visitors remote IP Address for their own reasons. In my case I want to record the IP address from a remote computer that uses a dynamic IP address. I need this information saved without user interaction. Right now I have a simple cron script set up on the remote servers that will
upgrading to rails 3.
Fri, 03 Sep 2010 09:32:17 UT
I've installed rails_upgrade plugin with ruby script/plugin install [link]. Then if I run rake rails:upgrade:check it says rake aborted! no such file to load -- initializer What I've missed?
Using Factory Girl with has many relationship
Fri, 03 Sep 2010 10:07:53 UT
Hello, I have this kind of relation: class Article < ActiveRecord::Base has_many :comments end class Comment < ActiveRecord::Base belongs_to :article attr_protected :article_id end The default scenario inside controllers looks like: @article = Article.create(:title => "foobar")
Pass selected value in combo as a parameter
Fri, 03 Sep 2010 10:35:27 UT
Hi, I have a select in my form: <%= select @issue_type, "name", @issue_types.collect {|p| [p.name, p.id]} %> What I need to do is execute a method passing the value selected in the combo. I've tried lot of things, but I couldn't. @issue_type is created in the controller and I assigned the first value
Rack gem in not getting unpacked
Fri, 03 Sep 2010 12:46:39 UT
Hi All, my server is having rack gems as: rack (1.2.1, 1.1.0, 1.0.1, 1.0.0) when i run the following command in my project/vendor/gems folder: gem unpack rack-1.0.0 It shows the following error message: Error: Gem 'rack-1.0.0' not installed. Any idea on this?? Thanks, Saurabh
nested form + partial + collection_select [No novato]
Fri, 03 Sep 2010 13:18:20 UT
¡Hola! Tengo lo siguiente: Una página donde esta mi modelo docencia que a su vez le voy agregando todos los dictados de carreras: <fieldset> <% f.fields_for :dictados do |dictado_form| %> <%= render :partial => 'dictado', :locals => { :f => dictado_form } %> <% end %> <%= add_child_link "Agregar un dictado de carrera", f, :dictados %>
RoR with Existing tables in database using Postgresql
Fri, 03 Sep 2010 10:16:26 UT
Hi, I am new bee to Rais. I need to create a Rails application with existing database with several number of tables. When i came across web, I didn't find any fruitful ideas for developing application using existing tables. Everything i found was to create new database with Create, Edit, Insert feature. I need to create a application using existing postgresql database
rails 2 or ralis 3, which is better for a new project in real life?
Fri, 03 Sep 2010 10:00:00 UT
Hi, Our team decided to use rails to develop our new web application project. Some of our team members think we should ues rails 3 for our new application, beacuse they have many great new features. But the others doesn't agree with that, they said: "There has been many applications based on rails2. Rails 3 are too new to use for a real project. It may have
I have an issue that I can't solve at all
Fri, 03 Sep 2010 11:15:05 UT
Hello I have a problem, I want to switch my merb project to Rails3. Can you help to deal with it?
Problema con parámetros en collection_select (No novato)
Fri, 03 Sep 2010 15:03:39 UT
Hola a tod@s, Les cuento... Tengo lo siguiente en aplicación: Una página donde esta mi modelo docencia que a su vez le voy agregando todos los dictados de carreras: <fieldset> <% f.fields_for :dictados do |dictado_form| %> <%= render :partial => 'dictado', :locals => { :f => dictado_form }
Using Rails 3 with Ruby 1.9
Fri, 03 Sep 2010 15:53:28 UT
Can we use Ruby 1.9 and Rails 3 together? Last time I tried this Rails became angry and told me I couldn't (or shouldn't). So, maybe I am missing the blog entry on this subject, but when will Ruby1.9 and Rails 3 play nice?
Google maps -> sending coördinates
Fri, 03 Sep 2010 16:13:32 UT
I need to send geo coördinates from a mysql database to a google maps javascript. There´s no problem to get them into rails...But how can i send them to javascript ? I know javascript is client side so i think it´s impossible to include ruby variables... Suggestions ? Thanks
2.3.5 guide
Fri, 03 Sep 2010 16:52:58 UT
It seems the guide at [link] has been updated to 3.0. I am still using 2.3.5 with plans of upgrading. Any ideas on how I can get the older guide? Thanks
invalid byte sequence in UTF-8 , need to re-encode ?
Fri, 03 Sep 2010 17:34:08 UT
I have a string coming from an email body : (rdb:1) body " Le 3 sept. 2010 340 19:06, Event Seve Test a 351crit : > Please answer the question by writing an X at the chosen places : > > are you coming : > > YES: X > > NO:_ > > thanks for you answer > > the Seve Ballesteros"
yield, helpers with blocks, and double-output
Fri, 03 Sep 2010 17:38:27 UT
Hello, I'm having a hard time understanding how you are supposed to write helpers that take blocks now in Rails 3. According to 7.4.2 here: [link] you are supposed to write your helpers to return their result as text, rather than append to the accumulating content.
Has_and_belongs_to_many form with check_box
Fri, 03 Sep 2010 18:37:34 UT
Hi, I have 2 models, user and project. When I edit my profile I wan't to check the projects I wan't to follow. So here is my code: <% form_for @user do |f| %> ... <% for project in @projects %> <% fields_for "user[project_attributes][]", project do <li> <%= project_form.check_box "checked", {:checked =>
net-ldap-0.1.1 gives invalid filter syntax cuz of parenthesi
Fri, 03 Sep 2010 18:55:27 UT
Things like this won't work.. they fail with Invalid filter syntax filter = Net::LDAP::Filter.construct("n isnetgrouptriple=(,user,)") If I remove the parenthesis and it works fine. or if you use filter = Net::LDAP::Filter.eq( "nisnetgrouptriple", "(,user,)" ) then that works fine.. but i want to have compound statements and take them from a web front
modify objectclass - Object class violation/Operations error
Fri, 03 Sep 2010 19:16:50 UT
Summary: Is there anyway that someone has figured out how to adding/removing objectclasses to already existing entries using net-ldap 0.1.1? Detail: I am adding and deleting all sorts of ldap entries just fine. I can even make new entries with objectclasses, but when I want to remove an existing one or add another one I get 'object class
Rake task rails:upgrade:check is not working on windows. Rai
Fri, 03 Sep 2010 19:55:00 UT
Is there any solution to solve the problem of rake task rails:upgrade:check on windows ? I am getting this error ... Rake task fetching failed with (working directory: C:projects estproject) rake aborted! no such file to load -- popen4 C:ruby/lib/ruby/gems/1.8/gems/ rake-0.8.7/lib/rake.rb:2383:in 'raw_load_rakefile' (See full trace by running task with --trace)
failed to allocate memory
Wed, 01 Sep 2010 20:57:30 UT
Hi there! I have an app, that sometimes shows the above message at monrel.log and production.log. The app is running at production mode. mongrel.log ** Writing PID file to log/mongrel.pid [FATAL] failed to allocate memory ** Daemonized, any open files are closed. Look at log/mongrel.pid and



