[Rails] Re: api.rubyonrails.org site is taken over by a domain squatter

2010-04-20 Thread Frederick Cheung
On Apr 21, 12:28 am, Philip Hallstrom wrote: > Go here and download whatever set of rdocs you need... then you don't   > have to worry about the official site anymore :) > or generate the docs locally (rake doc:rails) like that you don't have to worry about having an internet connection > http:

[Rails] Re: Why not Rails with FastCGI?

2010-04-20 Thread Frederick Cheung
On Apr 21, 3:03 am, Sven Svenson wrote: > When I started using Rails around version 0.9, FastCGI was considered > one of the best ways to deploy Rails. That went out of fashion but I > don't know why. Then Mongrel was the hot thing and I've heard about > Phusion Passenger. > > What is wrong with

[Rails] [ANN]VTD-XML 2.8

2010-04-20 Thread Jimmy Zhang
VTD-XML 2.8 has been released. Please visit https://sourceforge.net/projects/vtd-xml/files/ to download the latest version. a.. Expansion of Core VTD-XML API a.. VTDGen adds support for capturing white spaces b.. VTDNav adds support for suport for getContentFragment(), recoverNode() an

Re: [Rails] Re: api.rubyonrails.org / guides.rubyonrails.org

2010-04-20 Thread Wang Li
does anyone know the ip of rubyonrails.org? then we could set it in our hosts file and visit the site properly or any docs mirror sites? I want docs... 2010/4/21 Vikrant Chaudhary > bump. > > On Apr 21, 1:50 am, Dieter Lunn wrote: > > The registrar is being a jacka** or payment wasn't recei

Re: [Rails] Re: api.rubyonrails.org / guides.rubyonrails.org

2010-04-20 Thread Wang Li
http://railsapi.com is perfect 2010/4/21 Wang Li > does anyone know the ip of rubyonrails.org? > > then we could set it in our hosts file and visit the site properly > > or any docs mirror sites? I want docs... > > > > 2010/4/21 Vikrant Chaudhary > > bump. >> >> On Apr 21, 1:50 am, Dieter Lunn

[Rails] [JOBS] Unusual UnHappy-Couples Startup needs Tech Advisor for One Time only or 2hrs/wk

2010-04-20 Thread eCoupleCoach
Tech Advisor to Unusual Social Venture Startup This position is for an unusual Social Venture Internet Startup which will be using a robust conceptual advance web application to help the 95% of unhappy marriages/ couples in general in the Western Hemisphere who cannot afford or will not trust a

[Rails] Re: Gem install/update errors

2010-04-20 Thread Wayne
Try doing a "gem sources" and see if one of your sources is http://gems.rubyonrails.org If it is, remove it with "gem sources --remove http://gems.rubyonrails.org";. I had the same problem today, I think it is related to the issue that rubyonrails.org is having with their domain name. ~W On Apr

[Rails] Why not Rails with FastCGI?

2010-04-20 Thread Sven Svenson
When I started using Rails around version 0.9, FastCGI was considered one of the best ways to deploy Rails. That went out of fashion but I don't know why. Then Mongrel was the hot thing and I've heard about Phusion Passenger. What is wrong with deploying Rails with FastCGI? Was it just some sort o

[Rails] solving the error when running gem install or gem update

2010-04-20 Thread roy
when seeing ERROR: While executing gem ... (ArgumentError) uri scheme is invalid try looking into your gem sources run gem sources and then remove all weird or unnecessary sources until you are left with only http://gems.rubyforge.org then try to install or update a gem and you'll hopefully

[Rails] Re: Gem install/update errors

2010-04-20 Thread artixan
Check your Gem sources with: `gem sources` and remove http://gems.rubyonrails.org if it's listed. The main rubyonrails.org domain is down. ihth --arnie riquelme On Apr 20, 8:58 am, Stacy Vlasits wrote: > %USERPROFILE%\Documents\Programs\rails_apps\history> gem update rails > ERROR:  While execu

[Rails] Re: api.rubyonrails.org / guides.rubyonrails.org

2010-04-20 Thread Tim
what problem is that? On Apr 20, 11:37 am, Philip Hallstrom wrote: > It's everyone.  Same problem with the domain registrar as last year. > > On Apr 20, 2010, at 11:20 AM, Alan Gutierrez wrote: > > > > > Is it just me, or is everyone seeing backpack girl > > athttp://api.rubyonrails.org/ > > and

[Rails] Re: Conditionally adding a link to a form -- how?

2010-04-20 Thread Bob Smith
Try using params instead of variables. The variables lose scope when changing between views/controllers and once that happens, the value becomes nil. Instead of @show_new_expanse_page = true try params['new_expense_page'] = true and the value will persist until used. the test for this would be cha

[Rails] Select inside a hidden div

2010-04-20 Thread Bob Smith
Is there any way to use select inside a hidden div block with a model object for the select items ? I have the block showing and hiding OK with observe_field, but the variable I'm using to see whether to show/ hide seems to be the only one allowed by the :with option to observe_field, so I can't se

[Rails] Re: Unable to set default_url_options[:host] for Action Mailer

2010-04-20 Thread Christopher Small
> If so, try putting it inside your mailer class: > > default_url_options[:host] = RAILS_ENV != production ? >"development_url.com" : "production_url.com" > I would recommend using Ryan Bates nifty generators gem (http://github.com/ryanb/nifty-generators). This lets you generate a

[Rails] Re: Gem install/update errors

2010-04-20 Thread Wayne The
Stacy Vlasits wrote: > %USERPROFILE%\Documents\Programs\rails_apps\history> gem update rails > ERROR: While executing gem ... (ArgumentError) > uri scheme is invalid > Updating installed gems > Process gem exited with code 1 > > I received this error first while attempting 'gem install will_p

[Rails] Re: api.rubyonrails.org / guides.rubyonrails.org

2010-04-20 Thread Vikrant Chaudhary
bump. On Apr 21, 1:50 am, Dieter Lunn wrote: > The registrar is being a jacka** or payment wasn't received in time. > > Dieter Lunnhttp://www.coder2000.ca > > > > On Tue, Apr 20, 2010 at 1:31 PM, Mario Antonetti wrote: > > I'm seeing this too.  Anyone know what's going on? > > > Mario > > > On T

[Rails] STI Design Questions

2010-04-20 Thread DGerton
It's often hard to keep up with changes in RoR, especially when you're still learning. A lot information on the web is for older versions of RoR. So I want to make sure this design using single-table inheritance (STI) makes sense. My design need is identical to this: I have a Quiz class, a Quiz ha

Re: [Rails] Re: User activation

2010-04-20 Thread Hassan Schroeder
On Tue, Apr 20, 2010 at 5:51 PM, Rutvij Pandya wrote: >> restful_authentication has that built-in; have you read the docs? If >> so, what part are you having trouble with? >  trouble is - how the activation code is generated? Again -- have you read the docs? Or even any of the various online tu

[Rails] Re: User activation

2010-04-20 Thread Rutvij Pandya
Hassan Schroeder wrote: > On Tue, Apr 20, 2010 at 10:44 AM, Rutvij Pandya > wrote: > >> > restful_authentication has that built-in; have you read the docs? If > so, what part are you having trouble with? > > -- > Hassan Schroeder hassan.schroe...@gmail.com > twitter: @h

[Rails] Link directory in Rails - easy?

2010-04-20 Thread Ast Jay
Hey All, hope someone can give me an idea of how easy/difficult it would be to to create a link directory in Rails. Here's a brief spec: - People should be able to create an account and submit a link, either to a category or just tag it with some keywords. - There should be an option to allow pe

Re: [Rails] Re: api.rubyonrails.org site is taken over by a domain squatter

2010-04-20 Thread Philip Hallstrom
Go here and download whatever set of rdocs you need... then you don't have to worry about the official site anymore :) http://railsapi.com/ On Apr 20, 2010, at 4:26 PM, Moo wrote: API doesn't work with .com On Apr 20, 3:12 pm, jhaagmans wrote: You can use rubyonrails.com now. On Apr 20,

[Rails] Re: api.rubyonrails.org site is taken over by a domain squatter

2010-04-20 Thread Moo
API doesn't work with .com On Apr 20, 3:12 pm, jhaagmans wrote: > You can use rubyonrails.com now. > > On Apr 20, 10:11 pm, dan wrote: > > > is there a direct ip for ruby rails site? > > > -- > > You received this message because you are subscribed to the Google Groups > > "Ruby on Rails: Talk

Re: [Rails] Re: Rails 3 + Rspec 2 + Remarkable

2010-04-20 Thread Ho-Sheng Hsiao
I'm still banging my head against Remarkable AR. Here's the current problem: Rspec2 dynamically generated nested classes under example groups. So for example, when I do describe "foo" do end That block actually goes under Rspec::Core::ExampleGroup::Nested_1 Remarkable::AR overrides describe, ho

[Rails] Re: Database query question

2010-04-20 Thread Patrick Clas
I thought this was possible using the update_all method of ActiveRecord...no? If not, then I will just write native sql commands instead. -- 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] Can you recommend a great agile training program in the Bay Area?

2010-04-20 Thread drewB
Can anyone recommend a good few day training program for running agile teams in the Bay Area? I know there are a bunch out there but I was looking for some first hand recommendations. Basically, I am looking for a program that will help me implement agile processes in the development team I run.

[Rails] Re: Database query question

2010-04-20 Thread Marnen Laibow-Koser
Patrick Clas wrote: > I'm new to rails and I'm also new to database access so hopefully this > will be easy to answer, and hopefully I can explain it well enough to be > understood. > > I've got ActiveRecord objects that all relate to eachother. User and > Game have a many to many relationship co

Re: [Rails] User activation

2010-04-20 Thread Hassan Schroeder
On Tue, Apr 20, 2010 at 10:44 AM, Rutvij Pandya wrote: >  I am using restful authentication plug-in for user registration & > authentication. > >  What I want to do is, when user submit registration form, a link > containing activation code 'll be generated & is to be sent to user via > mail. > >

[Rails] Re: Spring Cleaning

2010-04-20 Thread Marnen Laibow-Koser
[Please quote when replying. It will make the context clearer.] David Zhu wrote: > my question was how exactly to make that helper method Try it. What part don't you understand? Best, -- Marnen Laibow-Koser http://www.marnen.org mar...@marnen.org -- Posted via http://www.ruby-forum.com/. --

[Rails] Re: FORM fields sent to the CONTROLLER

2010-04-20 Thread Marnen Laibow-Koser
David Zhu wrote: > Wait colin, I'm just hitting "Reply" at the bottom of the page. Isn't > that what I'm supposed to do? Yes, but then type your reply *after* the relevant lines in the quoted text (as I'm doing here). This is the order in which you'd have a conversation. Best, -- Marnen Laibow

[Rails] Re: api.rubyonrails.org site is taken over by a domain squatter

2010-04-20 Thread jhaagmans
You can use rubyonrails.com now. On Apr 20, 10:11 pm, dan wrote: > is there a direct ip for ruby rails site? > > -- > 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 rubyonrails-t...@googlegroups.com.

[Rails] Re: Smart localisation

2010-04-20 Thread jhaagmans
If I should believe the things I find on the internet, this is the correct approach for form labels: --- en: activerecord: attributes: user: last_name: Surname --- And then: <% form_for @user do |f| %> <%= f.label :last_name %> <%= f.text_field :last_name %> <% end %> Howe

Re: [Rails] xml from a var

2010-04-20 Thread сбк
Sorry, i mean object attribute. 2010/4/21 сбк > Make x variable class attribute by naming it @x and use next code in your > View : > <%= @x %> > > On Mon, Apr 19, 2010 at 8:45 PM, Chris Habgood wrote: > >> No I am doing this: >> >> def assert_xml_message(type,msg) >> x = gen_basic_xml >> x.re

[Rails] Re: User activation

2010-04-20 Thread khagimoto
oops, sorry, I guess I skipped your first sentence! I've never used restful-authentication plug-in, but it sounds like it already has support for what you're asking for: http://github.com/technoweenie/restful-authentication/blob/master/README.textile I do recommend authlogic after having used it

[Rails] Re: Spring Cleaning

2010-04-20 Thread David Zhu
my question was how exactly to make that helper method On Apr 20, 6:00 pm, Marnen Laibow-Koser wrote: > David Zhu wrote: > > Right now in my view, I have a whole HUGE clump of > > > <% if current_user %> and then <% if current_admin %> and then <% if > > current_teacher %> and then all that other

[Rails] Re: FORM fields sent to the CONTROLLER

2010-04-20 Thread David Zhu
Wait colin, I'm just hitting "Reply" at the bottom of the page. Isn't that what I'm supposed to do? I'm pretty sure everything is in chronological order as welll... what exactly do you mean? On Apr 19, 3:38 am, Sharagoz wrote: > I think he means how he can specify where the request is going to g

[Rails] Re: Ruby existing database

2010-04-20 Thread Marnen Laibow-Koser
Will Raffaele wrote: > Hello all from Ruby newbie, > > I'm sure this has been asked many times, but I can't find the answer. > > I would like to use Ruby for an existing database. > > It does not use id for the primary key, and the table name are not > plural. > > The tables are already loaded

[Rails] Re: reg exp

2010-04-20 Thread Marnen Laibow-Koser
ES wrote: > What would the reg expression be for a string of 13 consecutive digits > in javascript? > > var textfieldIdRegexp = /^\d{13}/; > > ? This has nothing to do with Rails, and should be asked on a JavaScript forum. Best, -- Marnen Laibow-Koser http://www.marnen.org mar...@marnen.o

[Rails] Re: Best practice around putting rails database info into git

2010-04-20 Thread Marnen Laibow-Koser
Pito Salas wrote: > This maybe too vague a question, but I wonder if there's some wisdom out > there for me to tap... > > Sometimes when I get ready to commit, git says that db/schema.rb has > changed. This is weird, and I think it's because I did a rake > db:migrate. Yes, that would probably be

[Rails] Re: Best practice around putting rails database info into git

2010-04-20 Thread Marnen Laibow-Koser
Vladimir Rybas wrote: > 1. I usually put my db/schema.rb to .gitignore. There's some rake task > to > create your database not from migrations, but from schema.rb. But I > didn't > see anybody alive doing this. I do it. > So, you don't really need this file in > your > repo. Completely wrong

[Rails] Re: Spring Cleaning

2010-04-20 Thread Marnen Laibow-Koser
David Zhu wrote: > Right now in my view, I have a whole HUGE clump of > > <% if current_user %> and then <% if current_admin %> and then <% if > current_teacher %> and then all that other stuff in my view. > > I have a ginourmous chunk of if and else statements in my views... is > there a way to

[Rails] Re: User activation

2010-04-20 Thread Marnen Laibow-Koser
Rutvij Pandya wrote: > khagimoto wrote: >> Not sure which plug-in you're using, but this does what you've >> described: >> http://github.com/matthooks/authlogic-activation-tutorial >> (See Also: http://github.com/binarylogic/authlogic_example) > > -- > > dear kh

[Rails] Re: User activation

2010-04-20 Thread Rutvij Pandya
khagimoto wrote: > Not sure which plug-in you're using, but this does what you've > described: > http://github.com/matthooks/authlogic-activation-tutorial > (See Also: http://github.com/binarylogic/authlogic_example) -- dear khagimoto, I am using "restful_authe

[Rails] Re: User activation

2010-04-20 Thread khagimoto
Not sure which plug-in you're using, but this does what you've described: http://github.com/matthooks/authlogic-activation-tutorial (See Also: http://github.com/binarylogic/authlogic_example) -- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" grou

[Rails] Spring Cleaning

2010-04-20 Thread David Zhu
Right now in my view, I have a whole HUGE clump of <% if current_user %> and then <% if current_admin %> and then <% if current_teacher %> and then all that other stuff in my view. I have a ginourmous chunk of if and else statements in my views... is there a way to make it prettier? The if and el

[Rails] A way to build

2010-04-20 Thread Thomas Allen
I would like to be able to easily build a string. Here is how I am doing it right now (I have omitted parts not relevant): In the layout: <%= title %> Which calls: module ApplicationHelper def title @title_parts.join ' | ' end end and @title_parts is build like so: class Ap

Re: [Rails] xml from a var

2010-04-20 Thread сбк
Make x variable class attribute by naming it @x and use next code in your View : <%= @x %> On Mon, Apr 19, 2010 at 8:45 PM, Chris Habgood wrote: > No I am doing this: > > def assert_xml_message(type,msg) > x = gen_basic_xml > x.response do >x.tag!(type) do > x.message msg >end >

Re: [Rails] api.rubyonrails.org / guides.rubyonrails.org

2010-04-20 Thread Dieter Lunn
The registrar is being a jacka** or payment wasn't received in time. Dieter Lunn http://www.coder2000.ca On Tue, Apr 20, 2010 at 1:31 PM, Mario Antonetti wrote: > I'm seeing this too.  Anyone know what's going on? > > Mario > > On Tue, Apr 20, 2010 at 1:20 PM, Alan Gutierrez wrote: >> >> Is i

Re: [Rails] api.rubyonrails.org / guides.rubyonrails.org

2010-04-20 Thread Mario Antonetti
I'm seeing this too. Anyone know what's going on? Mario On Tue, Apr 20, 2010 at 1:20 PM, Alan Gutierrez wrote: > Is it just me, or is everyone seeing backpack girl at > http://api.rubyonrails.org/ > and http://guides.rubyonrails.org/ ? > > Alan Gutierrez > http://twitter.com/bigeasy > > -- Y

[Rails] Re: Re: Can I access another apps mysql database with my rails app?

2010-04-20 Thread Ast Jay
Philip Hallstrom wrote: > On Apr 20, 2010, at 1:16 PM, Ast Jay wrote: > >>> >> Would you know if it is easy enough to share sessions with a forum app >> such as vbulletin? > > Unlikely to be easy. But if the cookies are available and you're > willing to parse the information you could do whateve

Re: [Rails] Re: Can I access another apps mysql database with my rails app?

2010-04-20 Thread Philip Hallstrom
On Apr 20, 2010, at 1:16 PM, Ast Jay wrote: Philip Hallstrom wrote: mysql database directly? Guess I would just need to give it username/pw for the db, and the mysql query? Is it going to be easy enough to do, or should I stick with a full php solution (can't drop PHP as we need a full fe

[Rails] Re: reg exp

2010-04-20 Thread Robert Walker
ES wrote: > What would the reg expression be for a string of 13 consecutive digits > in javascript? > > var textfieldIdRegexp = /^\d{13}/; Do you mean a string matching exactly 13 digits? /^\d{13}$/ Or, a string containing a 13 digit sequence? /\d{13}/ Or, string starting with 13 consecu

[Rails] Re: Javascript validations for word count in fckeditor

2010-04-20 Thread Robert Walker
Robert Walker wrote: > And to get you started you could base a solution around: > my_text_field.split(/\s/).length Correction: Make sure you get the string value for the text field for use with split(): jQuery example: $('#my_text_field').val().split(/\s/).length -- Posted via http://www.ruby-f

[Rails] Re: Can I access another apps mysql database with my rails app?

2010-04-20 Thread Ast Jay
Philip Hallstrom wrote: >> mysql database directly? >> >> Guess I would just need to give it username/pw for the db, and the >> mysql >> query? >> >> Is it going to be easy enough to do, or should I stick with a full php >> solution (can't drop PHP as we need a full featured forum like vB). > >

[Rails] Re: api.rubyonrails.org site is taken over by a domain squatter

2010-04-20 Thread dan
is there a direct ip for ruby rails site? -- 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 rubyonrails-t...@googlegroups.com. To unsubscribe from this group, send email to rubyonrails-talk+unsubscr...@

[Rails] Re: Javascript validations for word count in fckeditor

2010-04-20 Thread Robert Walker
sunny wrote: > I need to count the number of words in fckeditor using javascript Did you make any effort to search this out for yourself. There are plenty of examples of this to be found using a simple Google search. Google: javascript word count And to get you started you could base a solution

Re: [Rails] Can I access another apps mysql database with my rails app?

2010-04-20 Thread Philip Hallstrom
Sorry if the answer is obvious (nube alert) but would it be possible for me to access the DB of a php app using a mysql database, from within my Rails app? I want to install my (php) forums in forum.site.com, and my main site (using rails) will be at the root, site.com - so could I list the

[Rails] Re: Best practice around putting rails database info into gi

2010-04-20 Thread Robert Walker
Pito Salas wrote: > This maybe too vague a question, but I wonder if there's some wisdom out > there for me to tap... > > Sometimes when I get ready to commit, git says that db/schema.rb has > changed. This is weird, and I think it's because I did a rake > db:migrate. > > So my question is, what'

[Rails] Can I access another apps mysql database with my rails app?

2010-04-20 Thread Ast Jay
Sorry if the answer is obvious (nube alert) but would it be possible for me to access the DB of a php app using a mysql database, from within my Rails app? I want to install my (php) forums in forum.site.com, and my main site (using rails) will be at the root, site.com - so could I list the latest

[Rails] Re: Best practice around putting rails database info into git

2010-04-20 Thread Pito Salas
Vladimir Rybas wrote: > 1. I usually put my db/schema.rb to .gitignore. There's some rake task > to > create your database not from migrations, but from schema.rb. But I > didn't > see anybody alive doing this. So, you don't really need this file in > your > repo. > > 2. You run your new migrat

[Rails] Re: Smart localisation

2010-04-20 Thread jhaagmans
Oh an to be complete about the first thing: I know I can get the controller/action translations by doing t('controller.action.translation'), but I'd like to integrate my localisation more into my application. Of course I could write a method to extend t(), but I've done stuff like that before only

Re: [Rails] Ruby Summer of Code Project

2010-04-20 Thread Chad Woolley
On Tue, Apr 20, 2010 at 10:33 AM, Federico Builes wrote: > Hi, > > As part of my Ruby SOC proposals I'm thinking of working in the CI > idea posted in http://wiki.rubyonrails.org/rubysoc/2010/ideas > > Ideally, I'd like to do a two step proposal: first one would be > writing custom CI tool tailore

Re: [Rails] api.rubyonrails.org / guides.rubyonrails.org

2010-04-20 Thread Philip Hallstrom
It's everyone. Same problem with the domain registrar as last year. On Apr 20, 2010, at 11:20 AM, Alan Gutierrez wrote: Is it just me, or is everyone seeing backpack girl at http://api.rubyonrails.org/ and http://guides.rubyonrails.org/ ? Alan Gutierrez http://twitter.com/bigeasy -- You r

Re: [Rails] Best practice around putting rails database info into git

2010-04-20 Thread Vladimir Rybas
1. I usually put my db/schema.rb to .gitignore. There's some rake task to create your database not from migrations, but from schema.rb. But I didn't see anybody alive doing this. So, you don't really need this file in your repo. 2. You run your new migrations as soon as you get them. So, after pul

[Rails] api.rubyonrails.org / guides.rubyonrails.org

2010-04-20 Thread Alan Gutierrez
Is it just me, or is everyone seeing backpack girl at http://api.rubyonrails.org/ and http://guides.rubyonrails.org/ ? Alan Gutierrez http://twitter.com/bigeasy -- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send

[Rails] Re: Rails 3 + Rspec 2 + Remarkable

2010-04-20 Thread cjharrelson
I care most about: Remarkable ActiveRecord Remarkable Rails Do you have anything working yet? I bundled your fork and could not get it working this past weekend. Any status info would be appreciated. Also, if you need some help please let me know. I am willing to contribute. I am midas on Gi

Re: [Rails] Ruby existing database

2010-04-20 Thread Craig White
On Tue, 2010-04-20 at 19:50 +0200, Will Raffaele wrote: > Hello all from Ruby newbie, > > I'm sure this has been asked many times, but I can't find the answer. > > I would like to use Ruby for an existing database. > > It does not use id for the primary key, and the table name are not > plural.

[Rails] Ruby Summer of Code Project

2010-04-20 Thread Federico Builes
Hi, As part of my Ruby SOC proposals I'm thinking of working in the CI idea posted in http://wiki.rubyonrails.org/rubysoc/2010/ideas Ideally, I'd like to do a two step proposal: first one would be writing custom CI tool tailored specifically for Rails where we can see more relevant information. T

Re: [Rails] Re: Hello i new user Ruby On rails

2010-04-20 Thread agung sukariman putra
I am using windows XP sp3.. it suck,.. soon i will buy macbook ,. -- 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 rubyonrails-t...@googlegroups.com. To unsubscribe from this group, send email to rubyo

[Rails] Ruby existing database

2010-04-20 Thread Will Raffaele
Hello all from Ruby newbie, I'm sure this has been asked many times, but I can't find the answer. I would like to use Ruby for an existing database. It does not use id for the primary key, and the table name are not plural. The tables are already loaded and filled with data. How can I get CRUD

[Rails] User activation

2010-04-20 Thread Rutvij Pandya
Dear all, I am using restful authentication plug-in for user registration & authentication. What I want to do is, when user submit registration form, a link containing activation code 'll be generated & is to be sent to user via mail. User need to click the link sent to his mail Id to activat

[Rails] Re: Database query question

2010-04-20 Thread Patrick Clas
Amala Singh wrote: > If you cannot make this perform quicker in ruby language, I am afraid > that ROR will not be helpful in that way. > > ROR is basically a framework for quick development and maintenance. > To improve the performance you need to either do it via backend or > tweaking > the ROR

Re: [Rails] Re: Conditionally adding a link to a form -- how?

2010-04-20 Thread Colin Law
On 20 April 2010 16:03, RichardOnRails wrote: > Hi Colin, > >>> The following in app\views\vendors\show.html.erb works perfectly >>> <%= link_to 'New Expense', '/expenses/new' %> > >>> I have the following in app\controllers\vendors_controller.rb >>> class VendorsController < ApplicationController

[Rails] Gem install/update errors

2010-04-20 Thread Stacy Vlasits
%USERPROFILE%\Documents\Programs\rails_apps\history> gem update rails ERROR: While executing gem ... (ArgumentError) uri scheme is invalid Updating installed gems Process gem exited with code 1 I received this error first while attempting 'gem install will_paginate' and have been unable to do

[Rails] Re: api.rubyonrails.org site is taken over by a domain squatter

2010-04-20 Thread Frederick Cheung
On Apr 20, 4:57 pm, dkindlund wrote: > All, > > Visitinghttp://api.rubyonrails.orgnow redirects to an domain > squatter page. > > If you're not seeing it (probably because the original site may still > be cached by an upstream proxy), look at CorelCDN's cached version of > the page: This seems

[Rails] Re: why is ActiveRecord tying to select nonex ID column?

2010-04-20 Thread Fearless Fool
Frederick Cheung wrote: > for a normal HABTM there is no corresponding model, so rows never get > updated by this code path. The habtm association generates sql > fragments directly and runs them > Furthermore, because habtm is usually used as a 'dumb' join table, > it's only ever a question of de

[Rails] Re: why is ActiveRecord tying to select nonex ID column?

2010-04-20 Thread Frederick Cheung
On Apr 20, 5:34 pm, Fearless Fool wrote: > So (apologies to Fred) this may be deeper than I thought: How does a > HABTM table EVER get updated?  From the Rails 1.9.1 > active_record/base.rb sources, update_attributes => save => > create_or_update => update.  The sources for update(): > [snip] >

[Rails] Re: why is ActiveRecord tying to select nonex ID column?

2010-04-20 Thread Fearless Fool
Fred, as I said: apologies! But since you clearly understand better than I do, I'm hoping you can enlighten me as to how HABTM tables ever get updated? Or how a single entry in a HABTM table gets deleted (since the delete method, like update, seems to depend on the existence of an id field)?

[Rails] Re: Database query question

2010-04-20 Thread Frederick Cheung
On Apr 20, 3:19 pm, Patrick Clas wrote: > I'm new to rails and I'm also new to database access so hopefully this > will be easy to answer, and hopefully I can explain it well enough to be > understood. > > I've got ActiveRecord objects that all relate to eachother.  User and > Game have a many t

[Rails] api.rubyonrails.org site is taken over by a domain squatter

2010-04-20 Thread dkindlund
All, Visiting http://api.rubyonrails.org now redirects to an domain squatter page. If you're not seeing it (probably because the original site may still be cached by an upstream proxy), look at CorelCDN's cached version of the page: http://api.rubyonrails.org.nyud.net/ $ nslookup rubyonrails.or

[Rails] Re: why is ActiveRecord tying to select nonex ID column?

2010-04-20 Thread Fearless Fool
So (apologies to Fred) this may be deeper than I thought: How does a HABTM table EVER get updated? From the Rails 1.9.1 active_record/base.rb sources, update_attributes => save => create_or_update => update. The sources for update(): # Updates the associated record with values matching

[Rails] Re: why is ActiveRecord tying to select nonex ID column?

2010-04-20 Thread Frederick Cheung
On Apr 20, 4:42 pm, Fearless Fool wrote: > My error in terminology -- it's not a join table, but rather a "fact" > table in the Dimensional Database sense.  Would it be any different if > this was a HABTM table? > > Frederick Cheung wrote: > > ...If you're going do be > > doing foo.save! (or foo

[Rails] reg exp

2010-04-20 Thread ES
What would the reg expression be for a string of 13 consecutive digits in javascript? var textfieldIdRegexp = /^\d{13}/; ? -- 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 rubyonrails-t...@google

Re: [Rails] Invitation tracking

2010-04-20 Thread saideep a.v.s
Hello, Simple way is by maintaining a table with a boolean, if accepted or not. I dont know if a plugin exists for this purpose. Best Wishes, Saideep Annadatha On Mon, Mar 22, 2010 at 10:11 PM, badnaam wrote: > Hi, > > Here is my use case... > > A user of the site can invite friends to jo

Re: [Rails] Heroku deployment...

2010-04-20 Thread anton effendi
please run 'heroku help' and look add public into heroku run it please.. Thank you On Tue, Apr 20, 2010 at 7:57 PM, shyam mohan wrote: > Hi > please help me... > > >git push heroku master > Warning: Permanently added the RSA host key for IP address to the list of > known hosts. > Permission d

Re: [Rails] Re: Caching of data on server?

2010-04-20 Thread Peter Hickman
I have done something similar with a small data set that was being referenced a lot. In the end however the improvement, whilst noticeable, was not that significant. Does this data set used as it is or is it transformed before use? If so it might make sense to cache the transformed data or even t

[Rails] Re: why is ActiveRecord tying to select nonex ID column?

2010-04-20 Thread Fearless Fool
My error in terminology -- it's not a join table, but rather a "fact" table in the Dimensional Database sense. Would it be any different if this was a HABTM table? Frederick Cheung wrote: > ...If you're going do be > doing foo.save! (or foo.update_attributes which calls save) then you > need a

[Rails] Re: Caching of data on server?

2010-04-20 Thread jhaagmans
Hi Pieter, Rails does some class caching in the default production environment. There's more you can do though. It depends on what kind of website you have. If you only serve semi-static content, caching your pages (or parts of it) will improve your speed incredibly. No queries will be made until

Re: [Rails] Caching of data on server?

2010-04-20 Thread Fidel Viegas
Hi Hugo, Have a look at Rails caching. Here is a tutorial http://railscasts.com/episodes/115-caching-in-rails-2-1 All the best, Fidel. On Tue, Apr 20, 2010 at 2:55 PM, Pieter Hugo wrote: > Hi > > I am looking to speed up my rails application and am working through all > the SQL queries and try

[Rails] Smart localisation

2010-04-20 Thread jhaagmans
Hi, I have some trouble using Il8n. I've had these problems for a while now and always used rough workarounds, but as my productivity needs to go up another notch, I was wondering whether there was any way of avoiding these workarounds. For example: When I'm inside a view (say 'home/index') and u

[Rails] Re: Conditionally adding a link to a form -- how?

2010-04-20 Thread RichardOnRails
Hi Colin, >> The following in app\views\vendors\show.html.erb works perfectly >> <%= link_to 'New Expense', '/expenses/new' %> >> I have the following in app\controllers\vendors_controller.rb >> class VendorsController < ApplicationController >> @show_new_expense_page = true >> [snip[ >> I n

Re: [Rails] Database query question

2010-04-20 Thread Amala Singh
If you cannot make this perform quicker in ruby language, I am afraid that ROR will not be helpful in that way. ROR is basically a framework for quick development and maintenance. To improve the performance you need to either do it via backend or tweaking the ROR in a complex way to perform better

[Rails] Re: why is ActiveRecord tying to select nonex ID column?

2010-04-20 Thread Frederick Cheung
On Apr 20, 3:33 pm, Fearless Fool wrote: > @fred: You may be right, but in that case, the documentation is wrong. > From > > http://api.rubyonrails.org/classes/ActiveRecord/ConnectionAdapters/Sc... > > we have: > > > :id - Whether to automatically add a primary key column. Defaults > > to true.

[Rails] Caching of data on server?

2010-04-20 Thread Pieter Hugo
Hi I am looking to speed up my rails application and am working through all the SQL queries and trying to remove unnecessary queries. I thought of the following and would love to hear whether it is possible. I have one (smallish - about 40 records) table which only gets read by my app - no writi

[Rails] Re: Master table without related child record

2010-04-20 Thread Frederick Cheung
On Apr 20, 1:19 pm, Andy Jeffries wrote: > Having a bit of a braindead day, can anyone help with this.  I have three > models: Player, Game, Prediction (Player has_many :games, :through => > :prediction) > > I want a named_scope that finds games that the current player hasn't already > predicted

[Rails] Javascript validations for word count in fckeditor

2010-04-20 Thread sunny
I need to count the number of words in fckeditor using javascript -- 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 rubyonrails-t...@googlegroups.com. To unsubscribe from this group, send email to ruby

[Rails] Re: Hello i new user Ruby On rails

2010-04-20 Thread arscariosus
At first, I read Why's (poignant) Guide to Ruby as an introductory course then used Patrick Lenz's Simply Rails 2.0 and Agile Web Development With Ruby on Rails 3rd Edition too. Try reading The Rails Way too. :D What OS are you using? On Apr 20, 1:38 pm, agung sukariman putra wrote: > thx dude,.

Re: [Rails] Re: why is ActiveRecord tying to select nonex ID column?

2010-04-20 Thread Rimantas Liubertas
> And, as I hinted at, this IS a join table. Alas, it is not. At least in RoR terms. > What's interesting is that I cleared the table and rebuilt it -- no > error.  When I tried to update the entire table (with identical values), > it gave the same error on the same record.  Curiouser and curious

Re: [Rails] Re: why is ActiveRecord tying to select nonex ID column?

2010-04-20 Thread Michael Pavling
On 20 April 2010 15:33, Fearless Fool wrote: > And, as I hinted at, this IS a join table. It doesn't look like one to me - they tend to just have two fields; one for each foreign key. If it's a join table using a :through relationship, it still exists as a model in its own right, and needs an id

[Rails] Re: why is ActiveRecord tying to select nonex ID column?

2010-04-20 Thread Fearless Fool
Frederick Cheung wrote: > It is a pretty fundamental assumption of Active Record that tables > have a primary key. There is (or at least there used to be) a plugin > out there that added support for composite primary keys > > Fred @fred: You may be right, but in that case, the documentation is wr

[Rails] Best practice around putting rails database info into git

2010-04-20 Thread Pito Salas
This maybe too vague a question, but I wonder if there's some wisdom out there for me to tap... Sometimes when I get ready to commit, git says that db/schema.rb has changed. This is weird, and I think it's because I did a rake db:migrate. So my question is, what's the best practice relating to pu

  1   2   >