[Rails] Re: How to use Time type in rails
Can you post your schema.rb? On Jan 21, 10:45 pm, Zhao Yi wrote: > Bobnation wrote: > > Are you using Time.now to assign the time? > > Yes, I use Time.now. > -- > Posted viahttp://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 rubyonrails-talk@googlegroups.com To unsubscribe from this group, send email to rubyonrails-talk+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~--~~~~--~~--~--~---
[Rails] Re: noob question about development mode
Interesting way of doing things, and I'm not 100% sure what your OS environments on your machines are, but it really is kind of nice to be able to develop on separate machines with something as simple as "thin start" on the machine and the using Git to handle the source. Just an idea. On Jan 21, 10:24 pm, Kyle Wakefield wrote: > Mark Reginald James wrote: > > Kyle Wakefield wrote: > > >> If not, does someone know what I could be missing in my Apache > >> configuration that is keeping me from accessing development mode? > > > Are you using Passenger (mod_rails)? If so, you need to add the > > "RailsEnv development" option to your VirtualHost config. > > > -- > > Rails Wheels - Find Plugins, List & Sell Plugins - > >http://railswheels.com > > Yes, I am using Passenger. The RailsEnv option was the fix. Thanks for > the Reply, I don't think I would have found that one. I was busy looking > though the Apache and Rails options; I kind of forgot that I even > installed Passenger. > > Jason White wrote: > > are you trying to develop on your local machine? > > I'm trying to develop on a local server from another machine. It's > probably not the easiest/best way to go but I don't really know enough > to know the difference yet... > -- > Posted viahttp://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 rubyonrails-talk@googlegroups.com To unsubscribe from this group, send email to rubyonrails-talk+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~--~~~~--~~--~--~---
[Rails] Re: How to link_to a file out side rails application
That's a good question, and I'll let someone else handle it as I leave work tonight. However, I might recommend probably starting up one thread on the mailing list and asking your questions in there. Will be easier to keep track of them if they are all in one place. Thanks! On Jan 21, 7:33 pm, Zhao Yi wrote: > I want to link to a file outside rails application. It is a text file > stored in rails server disk. When user click this link, the file will be > open. > > How can I do this? > > thanks. > -- > Posted viahttp://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 rubyonrails-talk@googlegroups.com To unsubscribe from this group, send email to rubyonrails-talk+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~--~~~~--~~--~--~---
[Rails] Re: How to use Time type in rails
Are you using Time.now to assign the time? On Jan 21, 7:44 pm, Zhao Yi wrote: > I defines a table and one of its column type is Time. I use ruby Time > class to assign the value to this column, but it always generate Sat Jan > 01 2000 time. Is the format different with the database and ruby class? > I use MySql database in Linux. > -- > Posted viahttp://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 rubyonrails-talk@googlegroups.com To unsubscribe from this group, send email to rubyonrails-talk+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~--~~~~--~~--~--~---
[Rails] Re: What version of rails am I running?
To go one step farther, I would recommend installing RubyGems from source and then installing Rails through RubyGems. Much better situation. On Jan 18, 7:24 pm, "Jeremy McAnally" wrote: > Yes, Ubuntu puts their own Rails binscript (written in *bash*. ugh!) > in there because apparently they hate you and the whole of the Rails > community for some reason. > > Try something like "rails --version". And file a bug with Ubuntu > because they're the ones who maintain their stupid script. > > --Jeremy > > On Sun, Jan 18, 2009 at 7:13 PM, Kedar Mhaswade > > > > wrote: > > > Frederick Cheung wrote: > >> On 19 Jan 2009, at 00:24, Kedar Mhaswade wrote: > > >> In what way does it fail ? > >> That aside, rails -v tells you what the latest version of rails on > >> your computer is, which isn't the same thing as what version your > >> rails apps are running. > >> That can be controlled by > >> - having RAILS_GEM_VERSION set to something in environment.rb > >> - having rails frozen into vendor/rails > > >> when you run script/console or script/server it should tell you what > >> version of rails its loading. > > >> Fred > > > Thank you. But I don't think rails -v works. I think I have rails 2.0.2 > > or something like that (and that's what I am trying to ascertain) but on > > my Ubuntu here is what happens: > > ke...@kedar-laptop:~/Projects/ror/people$ which rails > > /usr/bin/rails > > ke...@kedar-laptop:~/Projects/ror/people$ rails -v > > getopt: invalid option -- v > > Terminating... > > > -Kedar > > -- > > Posted viahttp://www.ruby-forum.com/. > > --http://jeremymcanally.com/http://entp.com/http://omgbloglol.com > > My books:http://manning.com/mcanally/http://humblelittlerubybook.com/(FREE!) --~--~-~--~~~---~--~~ 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-talk@googlegroups.com To unsubscribe from this group, send email to rubyonrails-talk+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~--~~~~--~~--~--~---
[Rails] Re: Stuck on Git message
If you are using vi/Vim ... try pressing Esc and then :qw and hit Enter. That should quit you out of there. On Jan 15, 3:17 pm, Pål Bergström wrote: > Michael Libby wrote: > > On Thu, Jan 15, 2009 at 1:10 PM, Fiver wrote: > > > What's your output from > > > git config --get core.editor > > > ? > > Nothing. > > I got the screencast at peepcode, which was very good. I'm more into git > now, thanks :-) > > -- > Posted viahttp://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 rubyonrails-talk@googlegroups.com To unsubscribe from this group, send email to rubyonrails-talk+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~--~~~~--~~--~--~---
[Rails] Re: Ruby Best Practices twitter feed
I am watching this intently. On Jan 10, 12:39 pm, Gregory Brown wrote: > Hi folks, > > Sorry to spam, but I wanted to let those interested in my book "Ruby > Best Practices"[0] know that I've started up a twitter feed[1] to keep > folks informed of the book progress. > > Because this book will become a creative commons licensed community > work only 9 months after it is published, I hope that folks can get > involved during the pre-publication stages by picking up a roughcut > and giving me feedback, or otherwise generally following the project. > I'll be sure to post to the twitter feed when anything interesting > related to the book crops up, so it'll be the easiest way to keep an > eye on what's going on. > > -greg > > [0]http://rubybestpractices.com > [1]http://twitter.com/rubypractices --~--~-~--~~~---~--~~ 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-talk@googlegroups.com To unsubscribe from this group, send email to rubyonrails-talk+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~--~~~~--~~--~--~---
[Rails] Re: 1 Page website :)
On Jan 8, 9:04 pm, typemismatch wrote: > Is there a way to create what is basically a 1 page website, something > that just does a redirect or a single submit form etc. It seems like > an entire Rails site with controllers etc is too much. > > Maybe something with a single .rb page .. who knows :) just learning > Rails. > > thanks > -c What you ask is definitely possible, but I would ask what you are exactly trying to do. --~--~-~--~~~---~--~~ 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-talk@googlegroups.com To unsubscribe from this group, send email to rubyonrails-talk+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~--~~~~--~~--~--~---
[Rails] Re: Problem in following Ruby 'Blog' Screencast
Take the "div" out of there ... that looks odd there. Just looking over it, that looks like the problem (maybe). However, I haven't watched the new screencast ... so I can't really tell you. On Jan 9, 9:54 am, Michael wrote: > Hi all, > > When attempting to follow the screencast, 'Creating a weblog in 15 > minutes with Rails 2', I've hit a problem when creating the > 'partial'. As soon as the index.html.erb, > > Listing posts > > <%= render :partial => @posts %> > > <%= link_to 'New post', new_post_path %> > > with _post.html.erb. > > <% div for post do %> > <%= link_to_unless_current h(post.title), post %> > <%= simple_format h(post.body) %> > <% end %> > > and show.html.erb, > > <%= render :partial => @post %> > > > <%= link_to 'Edit', edit_post_path(@post) %> | > <%= link_to 'Destroy', @post, :method => :delete, :confirm => "Are > you sure?" %> > <%= link_to 'See All Posts', posts_path %> > > > I'm getting the following error: > > SyntaxError in Posts#index > > Showing app/views/posts/_post.html.erb where line #1 raised: > > compile error > /Users/michael/Desktop/rails_demo/blog/app/views/posts/_post.html.erb: > 1: syntax error, unexpected kDO_BLOCK, expecting tCOLON2 or '[' or '.' > old_output_buffer = output_buffer;post = local_assigns > [:post];object = local_assigns[:object];post_counter = local_assigns > [:post_counter];;@output_buffer = ''; __in_erb_template=true ; div > for post do ; @output_buffer.concat "\n" > > ^ > /Users/michael/Desktop/rails_demo/blog/app/views/posts/_post.html.erb: > 5: syntax error, unexpected kENSURE, expecting $end > > Extracted source (around line #1): > > 1: <% div for post do %> > 2: <%= link_to_unless_current h(post.title), post %> > 3: <%= simple_format h(post.body) %> > 4: <% end %> > > Trace of template inclusion: app/views/posts/_post.html.erb, app/views/ > posts/index.html.erb > > Any ideas? > > ruby --version > ruby 1.8.6 (2008-03-03 patchlevel 114) [universal-darwin9.0] > > Cheers > Mike --~--~-~--~~~---~--~~ 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-talk@googlegroups.com To unsubscribe from this group, send email to rubyonrails-talk+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~--~~~~--~~--~--~---
[Rails] Re: routes.rb question
Try what was recommended and what does your controller look like? On Jan 8, 10:29 pm, Joshua Abbott wrote: > Richard, > > Why not just lose this line from your routes file: > > map.connect '/:controller/:action' > > Since map.resources came along, I always delete the default stuff that > comes in the routes file. See if /phrases/new works the way it should > after removing that line. > > -- Joshhttp://iammrjoshua.com > > > > Richard Schneeman wrote: > > I'm trying to go to localhost/phrases/new > > > where 'phrases' is my controller and 'new' is my action which will > > simply show my new.html.erb > > > In my routes i have: > > map.connect '/:controller/:action' > > > Yet every time i go to phrases/new, I get redirected to my show action > > >http://pastie.org/356249 > > > I can get around this if i use: > > map.connect '/:controller/:action.' > > > But i find it distasteful to have that period at the end of my URL. Any > > clue why everything gets redirected to :action => 'show' > > -- > Posted viahttp://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 rubyonrails-talk@googlegroups.com To unsubscribe from this group, send email to rubyonrails-talk+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~--~~~~--~~--~--~---
[Rails] Re: Installing Ruby on Rails
I'll add http://articles.slicehost.com/ to the list as well. On Jan 8, 8:26 pm, "jason white" wrote: > Windows, Mac, Linux? > > some > resourceswww.learningrails.comwww.railscast.comwww.envycast.comwww.railsinside.com > > there are quite a few more, but i know those off the top. > > Jason > > On Thu, Jan 8, 2009 at 7:53 PM, Johny ben > wrote: > > > > > crazy canuck wrote: > > > I am completely new to all of this. I was told by a potential employer > > > if I learned Ruby on Rails and PostgreSQL I would have a job in 6-9 > > > months. My dilemma is that I cant even seem to install it properly > > > lol. Please can someone give me the prompts and whether I have to be > > > SU or use sudo. thank you so very much. > > > try this.. > >http://www.tutorialspoint.com/ruby-on-rails-2.1/rails-installation.htm > > -- > > Posted viahttp://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 rubyonrails-talk@googlegroups.com To unsubscribe from this group, send email to rubyonrails-talk+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~--~~~~--~~--~--~---
[Rails] Re: Validating a legal subdomain
That is pretty much what I was going to recommend. On Jan 8, 9:40 pm, Jeff wrote: > I eventually settled on a regex that permits only letters, numbers and > hyphens. Close enough for my needs: > > validates_format_of :subdomain, > :with => /^[a-zA-Z0-9\-]*?$/, > :message => 'accepts only letters, numbers > and hyphens' > > Hope that's helpful! > > Jeff > > On Jan 8, 5:10 pm, scottmotte wrote: > > > I think what Jeff meant is how to validate the subdomain as a normal > > combination of letters and integers without a bunch of strange keys. > > He's not talking about authentication, he's talking about validation. > > > I'll post here if I get this going Jeff. I'm also working on a way. It > > looks like it will have to be a regular expression. > > > On Dec 12 2008, 12:33 am, Peter De Berdt > > wrote: > > > > On 11 Dec 2008, at 17:06, jeffpatter...@gmail.com wrote: > > > > > I have a Rails app that uses subdomains as account keys. Users name > > > > their own subdomains. How can I validate those subdomains as legal? > > > > Just like you would verify a user login. The subdomain then becomes > > > part of the login procedure. You store it in a table and you > > > "authenticate" the domain in a before_filter. > > > > Best regards > > > > Peter De Berdt > > --~--~-~--~~~---~--~~ 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-talk@googlegroups.com To unsubscribe from this group, send email to rubyonrails-talk+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~--~~~~--~~--~--~---
[Rails] Re: Versionning system
I haven't used the GUI that much, but I might take a look in the future. Personally, I happen to like CLI tools overall for many things. Even though Textmate is still one of my favorite editors, there is something nice about opening up VIM and using that for quick edit jobs. My opinion: try both! ;) On Jan 8, 12:31 pm, pepe wrote: > Thank you to all of you. > > I have been reading up about different tools and I was leaning towards > Git, among other things because of Github, as Robert mentioned. I > don't know much about the tool yet and I know there are 2 sides to it, > the shell screen and the GUI version. Is the same functionality > available in both areas, which one should I go with? > > Thanks a lot again. > > Pepe > > On Jan 8, 10:42 am, Fernando Perez > wrote: > > > pepe wrote: > > > Hi all. > > > > I want to apologize, I guess this is not the best place to post this > > > but I'm interested to know what RoR developers think. > > > > What would be a good open source versionning system for somebody that > > > has never used one? > > > > Thanks a lot. > > > > Pepe > > > We use Mercurial because back in time the support of Git on Windows was > > bad. On Mac and GNU/Linux, Mercurial and Git are both excellent choices, > > so you won't be wrong. Don't use SVN, it's out of the game for new > > commers. > > > -- > > Video training with screencasts athttp://www.digiprof.fr > > > -- > > Posted viahttp://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 rubyonrails-talk@googlegroups.com To unsubscribe from this group, send email to rubyonrails-talk+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~--~~~~--~~--~--~---
[Rails] Re: Which "acts_as_taggable" plugin is the best?
I just used acts_as_taggable_on and am very happy with it. On Jan 8, 3:36 am, Difei Zhao wrote: > Hi all, > > I want to implement tagging for my resources, but I found lots > "acts_as_taggable" available: "acts_as_tabble", "acts_as_taggable_on", > "acts_as_taggable_on_steroid", etc. Some of them are not in active > development, and I do not know which one is more popular. So, any > suggestions? Thanks in advance! > > Difei. > -- > Posted viahttp://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 rubyonrails-talk@googlegroups.com To unsubscribe from this group, send email to rubyonrails-talk+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~--~~~~--~~--~--~---
[Rails] Re: Slightly Off Topic: Rails/SVN/Capistrano...plus Git?
For a sole developer setup where you don't have legacy repos hanging around, I would really recommend git. I have been using it exclusively for the past year and really like the Git + GitHub combination. On Jan 8, 10:10 am, Jeff Pritchard wrote: > Mukund wrote: > > git-svn might be worth a look. But to be honest, I find it a > > headache to keep things in sync between two version control systems > > when different people update each system. > > > On Jan 8, 3:09 am, Jeff Pritchard > > I guess that was a critical piece of info I left out. This is for > projects where I'm the sole developer. > > thanks, > jp > -- > Posted viahttp://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 rubyonrails-talk@googlegroups.com To unsubscribe from this group, send email to rubyonrails-talk+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~--~~~~--~~--~--~---
[Rails] Re: RoR, Apache2, fcgid and ubuntu...
Didn't really do much, but I'm glad you got it up and running. Now THAT'S a good feeling. ;) On Jan 7, 11:36 pm, ZebaMomin wrote: > Hey... > Thanks a lot for your help > The problem was that I didn't enable the site by doing.. > a2ensite crsa > > So I was getting a 404 error > Now I have the site up and running..:-) > > Anyways...Thanks a lot for your help.. > > > > Bobnation wrote: > > > I would actually look at Passenger again and see where things went > > wrong. You can use Passenger along with just the MRI version of Ruby > > (I'm running it on Ruby 1.8.7 right now). > > > Check out some of the Slicehost articles if you want some step-by-step > > articles to follow: > >http://articles.slicehost.com/2008/5/1/ubuntu-hardy-mod_rails-install... > > > On Jan 7, 12:05 am, ZebaMomin wrote: > >> I'm using the module fcgid with apache and so along with it I need the > >> fcgi > >> gem. > >> I tried using fastcgi module but it would crashso I switched to fcgid > >> which is much reliable than fastcgi... > >> I've also installed and used phusion passenger and ruby enterprise > >> edition...but no use.... > >> It too gives me a 404 error:-(( > > >> Can you please suggest any other way in which I can SUCCESSFULLY deploy > >> my > >> rails application on apache? > >> Thanks. > > >> Bobnation wrote: > > >> > I guess my question would start with this: why are you using fcgi? > > >> > On Jan 6, 2:57 am, ZebaMomin wrote: > >> >> Hi. > >> >> I'm trying to deploy my rails application on ubuntu server using > >> apache2 > >> >> and fcgid..but have not been successful.. > >> >> I am using ruby 1.8.6, rails 2.2.2 and fcgi 0.8.7 gem... > >> >> I am able to start apache successfully and view the Aptana RadRails > >> >> welcome page..But giving my controller's name gives me a 404 error... > >> >> I have made required changes in my /public/.htaccess and > >> >> /public/dispatch.fcgi filesas=> > > >> >> .htaccess(w/o comments) > > >> >> AddHandler fastcgi-script .fcgi > >> >> AddHandler fcgid-script .fcgi > >> >> AddHandler cgi-script .cgi > >> >> Options +FollowSymLinks +ExecCGI > >> >> dispatch.*fcgi* > >> >> RewriteEngine On > >> >> RewriteRule ^$ index.html [QSA] > >> >> RewriteRule ^([^.]+)$ $1.html [QSA] > >> >> RewriteCond %{REQUEST_FILENAME} !-f > >> >> RewriteRule ^(.*)$ dispatch.fcgi [QSA,L] > > >> >> ErrorDocument 500 "Application errorRails application failed > >> to > >> >> start properly" > > >> >> dispatch.fcgi > > >> >> #!/usr/bin/ruby > >> >> require File.dirname(__FILE__) + "/../config/environment" > >> >> require 'fcgi_handler' > >> >> require 'rubygems' > >> >> require_gem 'fcgi' > >> >> RailsFCGIHandler.process! > > >> >> I am attaching my httpd.conf file... > > >> >> I have checked that my VirtualHost works perfectly...but it doesn't > >> seem > >> >> to start my rails application > > >> >> Can someone please tell me where am I going wrong > >> >> Thanks in advance.. > > >> >> -- > >> >> View this message in > > >> context:http://www.nabble.com/RoR%2C-Apache2%2C-fcgid-and-ubuntu...-tp2130562... > >> >> Sent from the RubyOnRails Users mailing list archive at Nabble.com. > > >> -- > >> View this message in > >> context:http://www.nabble.com/RoR%2C-Apache2%2C-fcgid-and-ubuntu...-tp2130562... > >> Sent from the RubyOnRails Users mailing list archive at Nabble.com. > > -- > View this message in > context:http://www.nabble.com/RoR%2C-Apache2%2C-fcgid-and-ubuntu...-tp2130562... > Sent from the RubyOnRails Users mailing list archive at Nabble.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 rubyonrails-talk@googlegroups.com To unsubscribe from this group, send email to rubyonrails-talk+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~--~~~~--~~--~--~---
[Rails] Re: RoR, Apache2, fcgid and ubuntu...
I would actually look at Passenger again and see where things went wrong. You can use Passenger along with just the MRI version of Ruby (I'm running it on Ruby 1.8.7 right now). Check out some of the Slicehost articles if you want some step-by-step articles to follow: http://articles.slicehost.com/2008/5/1/ubuntu-hardy-mod_rails-installation On Jan 7, 12:05 am, ZebaMomin wrote: > I'm using the module fcgid with apache and so along with it I need the fcgi > gem. > I tried using fastcgi module but it would crashso I switched to fcgid > which is much reliable than fastcgi... > I've also installed and used phusion passenger and ruby enterprise > edition...but no use > It too gives me a 404 error:-(( > > Can you please suggest any other way in which I can SUCCESSFULLY deploy my > rails application on apache? > Thanks. > > > > Bobnation wrote: > > > I guess my question would start with this: why are you using fcgi? > > > On Jan 6, 2:57 am, ZebaMomin wrote: > >> Hi. > >> I'm trying to deploy my rails application on ubuntu server using apache2 > >> and fcgid..but have not been successful.. > >> I am using ruby 1.8.6, rails 2.2.2 and fcgi 0.8.7 gem... > >> I am able to start apache successfully and view the Aptana RadRails > >> welcome page..But giving my controller's name gives me a 404 error... > >> I have made required changes in my /public/.htaccess and > >> /public/dispatch.fcgi filesas=> > > >> .htaccess(w/o comments) > > >> AddHandler fastcgi-script .fcgi > >> AddHandler fcgid-script .fcgi > >> AddHandler cgi-script .cgi > >> Options +FollowSymLinks +ExecCGI > >> dispatch.*fcgi* > >> RewriteEngine On > >> RewriteRule ^$ index.html [QSA] > >> RewriteRule ^([^.]+)$ $1.html [QSA] > >> RewriteCond %{REQUEST_FILENAME} !-f > >> RewriteRule ^(.*)$ dispatch.fcgi [QSA,L] > > >> ErrorDocument 500 "Application errorRails application failed to > >> start properly" > > >> dispatch.fcgi > > >> #!/usr/bin/ruby > >> require File.dirname(__FILE__) + "/../config/environment" > >> require 'fcgi_handler' > >> require 'rubygems' > >> require_gem 'fcgi' > >> RailsFCGIHandler.process! > > >> I am attaching my httpd.conf file... > > >> I have checked that my VirtualHost works perfectly...but it doesn't seem > >> to start my rails application > > >> Can someone please tell me where am I going wrong > >> Thanks in advance.. > > >> -- > >> View this message in > >> context:http://www.nabble.com/RoR%2C-Apache2%2C-fcgid-and-ubuntu...-tp2130562... > >> Sent from the RubyOnRails Users mailing list archive at Nabble.com. > > -- > View this message in > context:http://www.nabble.com/RoR%2C-Apache2%2C-fcgid-and-ubuntu...-tp2130562... > Sent from the RubyOnRails Users mailing list archive at Nabble.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 rubyonrails-talk@googlegroups.com To unsubscribe from this group, send email to rubyonrails-talk+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~--~~~~--~~--~--~---
[Rails] Re: RoR, Apache2, fcgid and ubuntu...
I guess my question would start with this: why are you using fcgi? On Jan 6, 2:57 am, ZebaMomin wrote: > Hi. > I'm trying to deploy my rails application on ubuntu server using apache2 > and fcgid..but have not been successful.. > I am using ruby 1.8.6, rails 2.2.2 and fcgi 0.8.7 gem... > I am able to start apache successfully and view the Aptana RadRails > welcome page..But giving my controller's name gives me a 404 error... > I have made required changes in my /public/.htaccess and > /public/dispatch.fcgi filesas=> > > .htaccess(w/o comments) > > AddHandler fastcgi-script .fcgi > AddHandler fcgid-script .fcgi > AddHandler cgi-script .cgi > Options +FollowSymLinks +ExecCGI > dispatch.*fcgi* > RewriteEngine On > RewriteRule ^$ index.html [QSA] > RewriteRule ^([^.]+)$ $1.html [QSA] > RewriteCond %{REQUEST_FILENAME} !-f > RewriteRule ^(.*)$ dispatch.fcgi [QSA,L] > > ErrorDocument 500 "Application errorRails application failed to > start properly" > > dispatch.fcgi > > #!/usr/bin/ruby > require File.dirname(__FILE__) + "/../config/environment" > require 'fcgi_handler' > require 'rubygems' > require_gem 'fcgi' > RailsFCGIHandler.process! > > I am attaching my httpd.conf file... > > I have checked that my VirtualHost works perfectly...but it doesn't seem > to start my rails application > > Can someone please tell me where am I going wrong > Thanks in advance.. > > -- > View this message in > context:http://www.nabble.com/RoR%2C-Apache2%2C-fcgid-and-ubuntu...-tp2130562... > Sent from the RubyOnRails Users mailing list archive at Nabble.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 rubyonrails-talk@googlegroups.com To unsubscribe from this group, send email to rubyonrails-talk+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~--~~~~--~~--~--~---
[Rails] Re: Rails Hosting
A $20 slice or a cheap VPS from somewhere would do the trick for you ... at least that is what it sounds like. On Jan 6, 3:41 pm, John Yerhot wrote: > > Ok, I'll check it out. And I guess the main thing I am looking for is > > a sandbox where I can test remote deploys with Cap and Git, setup the > > database, basically anything I would do with a "production" level > > app. > > in that case, I'd just get a $20 slice at Slicehost. --~--~-~--~~~---~--~~ 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-talk@googlegroups.com To unsubscribe from this group, send email to rubyonrails-talk+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~--~~~~--~~--~--~---
[Rails] Re: Rails apps packaging
Have you configured you application.rb so that the gems are included there? On Jan 5, 3:19 pm, Joshua Partogi wrote: > Well it moved the rails gems into the vendor/ directory in my apps, > but it doesn't move other gems that I use in my application. > > On Jan 6, 1:57 am, Rob Lacey wrote: > > > There are a few rake tasks for this > > > rake rails:freeze:edge > > rake rails:freeze:gems > > > HTH > > > RobL > > > Joshua Partogi wrote: > > > Dear all, > > > > How do I package a rails apps and distribute it? As I can see that > > > rails library is installed inside the Ruby gem folder and not inside > > > the apps. Now if I want to distribute this with my client, how can I > > > include those gems inside the application lib/ ? Or in other case lets > > > say I want to put the code inside git, how do I put those gems inside > > > the distribution? I'm a bit new with rails especially in distribution > > > of rails apps. > > > > 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 rubyonrails-talk@googlegroups.com To unsubscribe from this group, send email to rubyonrails-talk+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~--~~~~--~~--~--~---
[Rails] Re: Quick one! -- Project Messages!!
What did you name the method in your project controller? On Jan 5, 5:40 am, Dave Smith wrote: > > In my project view page you can see the messages (but they are truncated > > to save space). I want to have a "more" link that takes the user to > > another page which holds all the full project messages. > > > Do I create a page called messages.html.erb? > > > I would also like to be able to comment on each of the messages on the > > second page!?!? > > > Please can someone help me as I am a really stuck! > > > Thank you very much!! > > > Dave > > Anyone? > -- > Posted viahttp://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 rubyonrails-talk@googlegroups.com To unsubscribe from this group, send email to rubyonrails-talk+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~--~~~~--~~--~--~---
[Rails] Re: Installing RoR for a Newbie is a nightmare
I have to echo someone from above, why not try out a Linux distro instead. Whenever you are going to be deploying your app, it is probably going onto a box with some distro of Linux on it. I always like developing on a system as close to my deployment as possible, which means Ubuntu on my laptop, desktop, and any server I use. So far, that has been the best for me. --~--~-~--~~~---~--~~ 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-talk@googlegroups.com To unsubscribe from this group, send email to rubyonrails-talk+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~--~~~~--~~--~--~---
[Rails] Re: add an editor on my application
+1 for Textile or Markdown (my preference) ... try looking up rdiscount if you want to use Markdown, I'm sure there are better options out there. On Dec 29, 9:11 am, "Ivor Paul" wrote: > Hi > > I have limited experience with FCKEditor --http://www.fckeditor.net/ > > and slightly more exp with tinymce --http://tinymce.moxiecode.com/ > > but in my experience the better solution is to use textile > ->http://redcloth.org/&http://wiki.rubyonrails.org/rails/pages/RedClothsincethey > are simpler > and then harder for users to break. TinyMCE imho > gives the user to many options and since most people are not good with > layout they often make a bigger mess than if you gave them something like > redcloth/textile > > Regards > > On Mon, Dec 29, 2008 at 11:52 AM, Johny ben < > > rails-mailing-l...@andreas-s.net> wrote: > > > Does anyone have a good suggestion for the best editor that can I embed > > on my application.. > > -- > > Posted viahttp://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 rubyonrails-talk@googlegroups.com To unsubscribe from this group, send email to rubyonrails-talk+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~--~~~~--~~--~--~---
[Rails] Re: Your thoughts on "Enterprise Rails"
While I don't agree with much of what the book seems to be saying ... I'm an opinionated b...@$tard ... there are always things you can learn even from books that don't seem to be the best. I have some really crappy programming/technology books at home, but I could still learn a lot from them because the background allowed me to sift out the stuff. On Dec 28, 10:46 am, Wayne Molina wrote: > Hello and happy holidays, everyone! > > I received the book "Enterprise Rails" by Dan Chak as a Christmas gift > and started reading it; I wanted to gauge the community's thoughts on > this. Basically, Mr. Chak advocates a totally different approach to > how every other Rails book/tutorial explains how to develop Rails > applications. > > Firstly, he advocates you organize your application deeper than the > default Rails skeleton; for example he says to put all of your models > under a "physical" directory (e.g. app/models/physical) and to > separate them by module (e.g. Physical::Projects::Project). > > He also evangelizes Postgresql instead of MySQL, and suggests not > using migrations at all but using raw SQL to create the tables, > because he recommends that you NOT treat the database like a dumb data > store (something the rest of the Rails community seems to do and be > okay with) and make good use of check constraints, triggers, > referential integrity and the like at both the database level AND the > application level. He is against migrations because of the extremely > limited subset of SQL they allow for (i.e. no real constraints). > > Now, I come from a C# background so this stuff makes sense to me, but > at the same time I want to follow the best practices from the Rails > world where I'm looking to redefine myself. I agree with a lot of > what Mr. Chak says about organization, since the one major fault I > find with Rails is that it doesn't lend itself to organizing your > application like other frameworks (e.g. Django); for example if my > application contains 2 major parts (say a Blog application and a > Network application), Rails just smushes them both together under the > app directory, and their models/views/controllers are all kept > together instead of being separated (e.g. app/models/blog/, app/models/ > social). The problem with using the approach from Enterprise Rails is > that it pretty much means I cannot use the generators, unless I were > to redefine them to follow the "enterprise" structure. While that's > not a big deal, I can't help but think that I would be going "against > the grain" as far as my application is concerned - call me a bandwagon > jumper, but I always prefer to follow the community when it comes to > programming, instead of going off on my own. > > From reading the book, though, I can't seem to understand why the > Rails community has never done this from the start. Rails > applications are meant to be scalable, no? And the big ones have got > to scale if they get successful, right? The Rails app that Dan Chak > worked on, according to what he says in the book, ballooned to some > 188 classes; if other large Rails apps are like that, how do they > manage? > > Basically - I'm wondering if I should be following the advice in the > book from the get-go when I design my application, or if I should > follow the best practices of the Rails community and not worry about > the "enterprise" stuff until I need to (at which point it may or may > not be too late). Also remember that I am fairly new to Rails but I > still want to do things the "right" way. > > Any insight from experienced Rails developers would be appreciated - > when I started reading the book I couldn't believe that these things > are NOT done in the Rails world, because they seem like common sense > to me that any professional developer would do, and yet almost all of > the Rails people I've read about and talked to consider them to be > inconsequential. Maybe my vision is just skewed, coming from the > Microsoft world. --~--~-~--~~~---~--~~ 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-talk@googlegroups.com To unsubscribe from this group, send email to rubyonrails-talk+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~--~~~~--~~--~--~---
[Rails] Re: What to call Rails + merb
How about Ruby on Rails? Anyone? On Dec 26, 11:48 pm, Ken Wagner wrote: > Maybe Merle? > Merble? > Marble? > > Raileries? > Rhuberb? > Rumer? > -- > Posted viahttp://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 rubyonrails-talk@googlegroups.com To unsubscribe from this group, send email to rubyonrails-talk+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~--~~~~--~~--~--~---
[Rails] Re: Should I learn Ruby on Rails? What book?
The above mentions are great (and I love the Ruby for Rails book). I would also recommend Agile Web Development 3 (http://pragprog.com) SimplyRails 2 and The Art of Rails. Also, learn Ruby as well, you will be happy. On Dec 26, 8:39 am, Teedub wrote: > You will need to learn Ruby also > David A Black's book "Ruby for Rails" is excellent. He is also writing > "The well grounded Rubyist" which is due out soon and the preview is > great. David has the ability to explain things in a manner that > actually tells you how it works. Most other books I have read tell you > "this is just like the blah function in C or Pearl". If you don't know > c or pearl, you are SOL. > > Good luck and Welcome to the wonderful world of Ruby and Rails and now > Merb > > On Dec 26, 5:35 am, Andrius Chamentauskas wrote: > > > It is for rails 2.2 and i believe they will get updated as new rails > > versions are released. > > > On Dec 25, 7:04 pm, zero0x wrote: > > > > Thank you very much, it looks great :) > > > > Is this for the latest version - 2.2 ? (Or at least Rails 2) > > > > On Dec 25, 3:09 pm, Davo wrote: > > > > > Hi There, > > > > Welcome to the Rails community. > > > > > Just recently a new range of guides were released & the starting one > > > > to check out is 'Getting Started with Rails' > > > > That along with all the others can be found > > > > here:http://guides.rails.info/index.html > > > > > A great place to start > > > > HTH - Dave Porter > > > > > On Dec 25, 9:52 pm, zero0x wrote: > > > > > > Hey there, > > > > > > I'm a web developer, I've already mastered (well at least it sounds > > > > > good) another framework - PHP Symfony - it's a great framework and > > > > > it's very similiar to Ruby on Rails. > > > > > > But when I watch these screencasts I just feel like PHP language will > > > > > never be so simple and so - beautiful... > > > > > > As you're all here Rails experts I suppose you would advice me to > > > > > learn Rails. I thought I would buy the beta book Agile development, > > > > > but shouldn't I wait for the final release? > > > > > > Thank you all :) --~--~-~--~~~---~--~~ 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-talk@googlegroups.com To unsubscribe from this group, send email to rubyonrails-talk+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~--~~~~--~~--~--~---
[Rails] Re: Advice on Mac versus PC ?
I didn't read through everything, but why not also think of buying a cheap laptop and then dropping a modern Linux distro on the thing? I run Ubuntu on my Thinkpad X40 and could not be happier with it ... well, if they had a SSD that worked with my laptop I'd be a little bit happier. Just a thought. On Dec 26, 10:20 pm, "wbsurf...@yahoo.com" wrote: > Thanks for the advice, > > Can a mac read an external USB drive that came from a Windows XP > machine ? > > The mac sounds interesting. I like the idea of being able to pop open > a native shell to the system and do 'ps -ef' and see what is running > and be able to write a ruby script that does a fork() that works > correctly etc. > I use cygwin on windows, but it doesn't feel the same .. > > I know you can install dual windows/linux using VM-Ware or some such, > but it sounds complicated to me. I guess I don't like the idea of > reinstalling windows, but if I am going to stick with windows, I guess > I need to consider that. I'd be affraid that one of my backup CD's > would go bad or that I would screw it up somehow. I'm wondering if I > can backup windows to an external drive and reinstall it that way ? > > On Dec 26, 6:14 am, "solithsn...@googlemail.com" > > wrote: > > if u dont worry about the additional 500 bucks, buy the mac. it's so > > easy and intuitive to work on this OS - u'll love it. > > try to buy an refurbished mac, you'll get some extra bucks back ! > > search in the apple store for refurbished products and you safe about > > 20% ! > > > dont care about itunes. if u have your lib on a external drive, you > > could import your music simply. --~--~-~--~~~---~--~~ 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-talk@googlegroups.com To unsubscribe from this group, send email to rubyonrails-talk+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~--~~~~--~~--~--~---
[Rails] Re: thin server processes slowly growing in RAM size
I would see if there are ways for you to implement caching ... but it also seems like there is maybe a memory leak within your code causing some problems. I'm not expert, but those are my thoughts. On Dec 9, 9:43 am, Scott Kulik wrote: > When I initially start up my server I have two thin processes running > that are only about 200M in size. They slowly creep up a few megs an > hour until now a week later they are at 400M and 300M respectively. > > I realize that my site (http://wlodb.com) has some intensive pages that > take a couple seconds to render (most notablyhttp://wlodb.com/compounds > ) but I'm wondering if this is normal? I usually get about 500,000 page > hits a month. > > Should I have a cronjob to restart my server processes once a week or > should I just work on implementing some server side caching which should > resolve the issue? > > thanks! > -- > Posted viahttp://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 rubyonrails-talk@googlegroups.com To unsubscribe from this group, send email to rubyonrails-talk+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~--~~~~--~~--~--~---
[Rails] Re: free ruby on rails hosting?
The issue with Ruby on Rails is that it is not simple a language, it really is a domain-specific language with its own requirements. Rails is a framework and so it does not follow the same sorts of setups as simply running PHP would. I still recommend looking for a cheap VPS and rolling your own from there. I think you would be happier in the end. On Dec 11, 3:59 pm, Heinz Strunk wrote: > Greg Donald wrote: > > On Thu, Dec 11, 2008 at 2:47 PM, Heinz Strunk > > wrote: > >> does anyone know any free ror webspace? I don't wanna have my computer > >> running 24/7 for some small websites. > > >http://letmegooglethatforyou.com/?q=free+ror+webspace > > > -- > > Greg Donald > >http://destiney.com/ > > I of course tried google first but nothing found... > > Maybe that's the only option if there's no free ror webspace. > -- > Posted viahttp://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 rubyonrails-talk@googlegroups.com To unsubscribe from this group, send email to rubyonrails-talk+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~--~~~~--~~--~--~---
[Rails] Re: Where do I start?
Ryan gave a really good resource, and it will only get better. After that, start building and keep reading. Read blog posts, read source from other projects, read tons of books, and then when you think you can't read anymore ... read a novel and then read another book. Right now I recommend a few books: Agile Web Development 3 (Beta PDF right now) from PragProg.com Simply Rails 2 (great introduction, if a little shallow at times) Learning Rails (a little deeper and covers different skills at different times) The Art of Rails (a philosophical book more than how-to) Then, keep on reading other books, get yourself some Ruby books and learn Ruby, learn ... read, rinse, and read again. All the time, keep building different things. Test all of the time. Your original sites are going to suck, and you'll look back and get discouraged, but keeping building and keep going. On Dec 10, 2:27 pm, Painting With Purpose wrote: > I want to become a Rails web developer. I am not a programmer by any > means. I have built one static website and am familiar with HTML and > CSS. I know I'll need to learn Rails, and perhaps a list of other > things like SQL, JavaScript, Apache, Ruby etc. but I have no idea > where to start. > > Could you please offer any advice on what I need to learn and most > importantly what order I should learn them. > > Thank you, > > Chris --~--~-~--~~~---~--~~ 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-talk@googlegroups.com To unsubscribe from this group, send email to rubyonrails-talk+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~--~~~~--~~--~--~---
[Rails] Re: free ruby on rails hosting?
Do yourself a huge favor and just pay for hosting. You'll be FAR happier in the end. I still recommend maybe picking up a cheap slice from Slicehost and having some fun setting up stuff. On Dec 11, 2:47 pm, Heinz Strunk wrote: > Hey, > > does anyone know any free ror webspace? I don't wanna have my computer > running 24/7 for some small websites. > -- > Posted viahttp://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 rubyonrails-talk@googlegroups.com To unsubscribe from this group, send email to rubyonrails-talk+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~--~~~~--~~--~--~---
[Rails] Re: Ubuntu 8.10 is good for rails
I'm running Rails on Ubuntu 8.10 with no problems so far. On Dec 10, 11:53 pm, Nike Mike <[EMAIL PROTECTED]> wrote: > whether ubuntu 8.10 is good for working with rails 2.0.2 with ruby 1.8.6 > .since by default ubuntu 8.10 is having ruby 1.8.7 and 1.9.so > applications created using ruby 1.8.6 is facing problem with ruby > version 1.8.7 > -- > Posted viahttp://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 rubyonrails-talk@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~--~~~~--~~--~--~---
[Rails] Re: How can I use rails in my public_html
I would echo Matt in many ways. If possible, I recommend getting a VPS somewhere and working with that because you will learn a lot of valuable information about how Rails works. On Dec 5, 11:31 pm, Tristan <[EMAIL PROTECTED]> wrote: > I have no root permission on the server, only a public_html in my > $HOME. > The http server is not apache; it only support cgi script. > > Can I use rails in my public_html? --~--~-~--~~~---~--~~ 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-talk@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~--~~~~--~~--~--~---
[Rails] Re: Changing primary.. Rails/mysql
First thing I would ask is "why?" What is the reason behind the change? On Dec 5, 7:14 pm, Jay Mark <[EMAIL PROTECTED]> wrote: > I am using Rails 2.0.2 with mysql database > Migrate sets the primary key to id. > Is it possible to change it to another column? > If yes, how? > Thanks for your help > > Cypray. > -- > Posted viahttp://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 rubyonrails-talk@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~--~~~~--~~--~--~---
[Rails] Re: do you version control your "doc/plugins" directory?
Personally, I'm attempting to move away from plugins to gems as much as possible (using Rails 2.2.2 right now). However, I have been using plugins and I did version control them just for simplicities sake. If you are making changes to it, then definitely you would have to. On Dec 5, 10:08 pm, "Greg Hauptmann" <[EMAIL PROTECTED]> wrote: > do you version control your "doc/plugins" directory? Is one supposed > to be able to re-generate this from the plugins? (I don't see a --~--~-~--~~~---~--~~ 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-talk@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~--~~~~--~~--~--~---
[Rails] Re: rake test fails - pending migrations
I'm hoping the same. ;) On Dec 3, 9:17 pm, Phlip <[EMAIL PROTECTED]> wrote: > Bobnation wrote: > > Just remove the migration files themselves or make new migration files > > to remove the columns/tables. > > If your project is not yet deployed (which I suspect it is not!). --~--~-~--~~~---~--~~ 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-talk@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~--~~~~--~~--~--~---
[Rails] Re: rake test fails - pending migrations
Just remove the migration files themselves or make new migration files to remove the columns/tables. On Dec 3, 6:55 pm, Shantanu Pavgi <[EMAIL PROTECTED]> wrote: > Well, I need to remove some database tables from my application. So I am > using rake db:migrate:down to undo/remove migrations. Also, I have > changed (added/removed/modified) the code in model, view, controller, > and tests to make these changes. Now I need to run tests in order to > check everything is working. > > I can pull out an old copy from revision control system. But, what if > migrations that need to be removed are not the latest ones. Lets assume > that there are 30 > migrations. > - migration # 15 and 17 - are related to adding new tables > - migration # 22 and 25 - add column to above tables. > > So I need to remove/undo migrations 15, 17, 22, and 25. I need other > migrations as they are not related to these tables. What should I do in > such situation? > > I did db:migrate:down for above migrations and also made necessary > changes in the code and now trying to run tests. Am I following wrong > approach? > > Thanks, > Shantanu. > > > > James Mitchell wrote: > > That's an unusual question. The reason you have tests is to verify > > your code actually does what you think it's doing. If you migrate > > down, you add and/or remove model attributes, which (hopefully) your > > code depends on. And your tests should fail if you change that. That > > is, if your code doesn't break just trying to run the tests. > > > Are your trying to run a prior version of your app? If so, you should > > use your revision control system to pull down an older copy of the > > code and db:reset. > > > HTH > > > On 12/3/08, Shantanu Pavgi <[EMAIL PROTECTED]> wrote: > > > -- > > > -- > > James Mitchell > > -- > Posted viahttp://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 rubyonrails-talk@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~--~~~~--~~--~--~---
[Rails] Re: Can I export db data to fixtures?
I'm curious as to what you are using this for. On Dec 2, 1:00 am, Arthur Chan <[EMAIL PROTECTED]> wrote: > Brian Hogan wrote: > > Yeah there are a few plugins to do that. There's one called > > ar_fixtures that should work just fine. I don't know if it's > > supported any more but I know it still works fine. > > > On Mon, Dec 1, 2008 at 8:14 PM, Arthur Chan > > Thanks Brian, it seems to be what I want. :) > > -- > Posted viahttp://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 rubyonrails-talk@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~--~~~~--~~--~--~---
[Rails] Re: Rails on shared hosting
I've heard good things about Slicehost, http://www.slicehost.com/, and have been thinking about hosting any actual applications there if they ever get too big for my tiny Atom server I am currently running from my apartment's server shelf. On Dec 2, 6:45 am, Joshua Partogi <[EMAIL PROTECTED]> wrote: > I think I must agree with you on this. It's just shared hosting are > all about marketing when they said they support rails :-( > > Yeach the module is there and accessible from cPanel, but Rails can't > actually run. *sigh* > > Any good slice hosting that is recommended anyone? > > Cheers. > > On Dec 2, 5:14 pm, Bobnation <[EMAIL PROTECTED]> wrote: > > > I tried running a Rails app through cPanel a long time ago and gave up > > because I like to have finer control over everything. If money is not > > too much of an issue, I think you would be better served by signing up > > for a VPS from somewhere and then setting up your own virtual server > > to run the app on if for no other reason than to gain a good > > understanding for how Rails applications are served to your audience. > > --~--~-~--~~~---~--~~ 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-talk@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~--~~~~--~~--~--~---
[Rails] Re: Rails on shared hosting
I tried running a Rails app through cPanel a long time ago and gave up because I like to have finer control over everything. If money is not too much of an issue, I think you would be better served by signing up for a VPS from somewhere and then setting up your own virtual server to run the app on if for no other reason than to gain a good understanding for how Rails applications are served to your audience. --~--~-~--~~~---~--~~ 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-talk@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~--~~~~--~~--~--~---
[Rails] Re: valid? is not working in Rails 2.2.2
Glad to hear that it was cleared up. On Dec 1, 10:57 pm, Vipin Vm <[EMAIL PROTECTED]> wrote: > Hi guys... > > First of all Sorry ... :( . i had a plugin called gloc-1.1.0 in my > vender/plugin. That was causing the problem. > > Thanks guys, > Vipin > -- > Posted viahttp://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 rubyonrails-talk@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~--~~~~--~~--~--~---
[Rails] Re: valid? is not working in Rails 2.2.2
It just seems like there are too many conditions being tossed at the validation method from wherever you are setting up those variables. On Dec 1, 3:56 am, Vipin Vm <[EMAIL PROTECTED]> wrote: > Hi Rick > > when i commented the following line, it worked fine. > > validates_presence_of :user_name, :password, :email, :display_name > > then what could be wrong? > > Vipin > > -- > Posted viahttp://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 rubyonrails-talk@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~--~~~~--~~--~--~---
[Rails] Re: "You have a nil object" problem driving me crazy!
Could you maybe copy and paste it into pastie so that it is easier for everyone to look at? On Nov 30, 2:49 pm, John Doe <[EMAIL PROTECTED]> wrote: > > Is the code you're showing us cut-and-pasted from your views? It looks > > like it might be a typo (like @side_image for side_image), so to rule > > that out I wanted to be sure this is the actual template code. > > Hi David, > > Yes, it is an actual copy an paste. > > Thanks! > John > -- > Posted viahttp://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 rubyonrails-talk@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~--~~~~--~~--~--~---
[Rails] Re: Books recommendation
Oooo ... that looks like an interesting piece of reading. I will be checking it out very soon. I just picked up Learning Rails as well, so I can't give much of an opinion on it yet, but I will in the future. On Nov 30, 12:39 pm, Klaus Pieslinger <[EMAIL PROTECTED]> wrote: > A. "Foundation Rails 2" is your friend! I've found it has better > learning pace for me. > Cheers! --~--~-~--~~~---~--~~ 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-talk@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~--~~~~--~~--~--~---
[Rails] Re: How to go back to using webrick default server
Can you run gem update and that works fine? What gem version are you using? On Nov 30, 10:06 am, Mrmaster Mrmaster <[EMAIL PROTECTED] s.net> wrote: > Bobnation wrote: > > I'm just curious as to why you want to remove Mongrel, just a general > > question. > > > I would really add +1 to the idea of just adding in an alias in > > your .bashrc file just to make the server easier to start. > > > On Nov 30, 9:47 am, Mrmaster Mrmaster <[EMAIL PROTECTED] > > I really don't know the difference between mongrel and webrick so it is > not a technical dislike. I just started out using webrick and wanted to > continue using it but more importantly it seems that remove/unistall > commands in my gem is broken and I would like to fix them or know how to > fix them for the future problems that might occur. > -- > Posted viahttp://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 rubyonrails-talk@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~--~~~~--~~--~--~---
[Rails] Re: The verdict on Rails scaffolding
On Nov 30, 9:18 am, Robert Walker <[EMAIL PROTECTED]> wrote: > One thing I discovered about scaffolding, even as a starting point, is > that if you every want to use nested resources modifying the scaffolding > to fit what is needed is more work, and adds more risk, than just > building what you need from scratch. That's actually a fantastic point I was running into for a while until I decided to clean out the whole controller I had scaffolded and just wrote it myself and fixed all of the ridiculous problems I had created for myself. There is also nothing quite as satisfying to see the cleanness of a controller after you have built it from scratch. > Plus as mentioned you're more likely to write better tests/specs too. Anyone willing to teach me how to use Rspec? Anyone? Bueller? --~--~-~--~~~---~--~~ 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-talk@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~--~~~~--~~--~--~---
[Rails] Re: How to go back to using webrick default server
I'm just curious as to why you want to remove Mongrel, just a general question. I would really add +1 to the idea of just adding in an alias in your .bashrc file just to make the server easier to start. On Nov 30, 9:47 am, Mrmaster Mrmaster <[EMAIL PROTECTED] s.net> wrote: > Davo wrote: > > Try 'gem uninstall mongrel' > > ( if you have more than one version you will be asked which one ) > > Dave > > > On Nov 30, 3:19 pm, Mrmaster Mrmaster <[EMAIL PROTECTED] > > With the unistall command I get this error: > [EMAIL PROTECTED]:~/Desktop$ gem uninstall mongrel > ERROR: While executing gem ... (Gem::InstallError) > Unknown gem mongrel >= 0 > > Should I try to reinstall ruby since non of the commands are working? > -- > Posted viahttp://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 rubyonrails-talk@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~--~~~~--~~--~--~---
[Rails] Re: Books recommendation
Geez, I forgot The Rails Way there ... sorry. Another great book for use after you learn the basics and need to start looking at the "nitty gritty" more. On Nov 29, 11:23 am, "James Englert" <[EMAIL PROTECTED]> wrote: > I would agree that the The Rails Way is decent. It can be a bit hard to find > specific information though. > > Hope That Helps, > Jimhttp://jim-rants.com/coding-blog/ > > On Sat, Nov 29, 2008 at 9:37 AM, Rob Lacey <[EMAIL PROTECTED]>wrote: > > > > > I'd recommend these two for getting up and running. > > > The Rails Way > > Agile Web Development with Ruby on Rails > > > Really the best way to get started is to choose a project, start with > > the most basic element and develop it gradually until it becomes an > > awsome force to be reckoned with :) > > > RobL > > > packat wrote: > > > I am trying to bring myself up-to-speed on rails as fast as > > > possible. I am currently following an online book "Beginning Ruby > > > on Rails" by Steven Holzner. It is a decent book, however the book > > > seems to base on an out of date version of Rails and it has a number > > > of mistakes in the 4 sections I read so far. > > > > I am considering buying a copy of a more up-to-date book and would > > > like your expert opinion. If you are to buy a Ruby on Rails book > > > right now, which book would you choose? > > > A. For beginner and > > > B. For expert. > > > > Thanks in advance, > > > pax --~--~-~--~~~---~--~~ 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-talk@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~--~~~~--~~--~--~---
[Rails] Re: Books recommendation
Simply Rails 2 Agile Web Development v.3 (Beta PDF available at PragProg.com) The Art of Rails Advanced Rails Recipes Do a lot of reading and get on IRC. ;) I have all of those books and many more that deal with Rails 1.x as well and every book you purchase you will get something out of. The four above I would recommend at this moment along with getting some more general Ruby books as well just to learn some more there. On Nov 29, 11:23 am, "James Englert" <[EMAIL PROTECTED]> wrote: > I would agree that the The Rails Way is decent. It can be a bit hard to find > specific information though. > > Hope That Helps, > Jimhttp://jim-rants.com/coding-blog/ > > On Sat, Nov 29, 2008 at 9:37 AM, Rob Lacey <[EMAIL PROTECTED]>wrote: > > > > > I'd recommend these two for getting up and running. > > > The Rails Way > > Agile Web Development with Ruby on Rails > > > Really the best way to get started is to choose a project, start with > > the most basic element and develop it gradually until it becomes an > > awsome force to be reckoned with :) > > > RobL > > > packat wrote: > > > I am trying to bring myself up-to-speed on rails as fast as > > > possible. I am currently following an online book "Beginning Ruby > > > on Rails" by Steven Holzner. It is a decent book, however the book > > > seems to base on an out of date version of Rails and it has a number > > > of mistakes in the 4 sections I read so far. > > > > I am considering buying a copy of a more up-to-date book and would > > > like your expert opinion. If you are to buy a Ruby on Rails book > > > right now, which book would you choose? > > > A. For beginner and > > > B. For expert. > > > > Thanks in advance, > > > pax --~--~-~--~~~---~--~~ 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-talk@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~--~~~~--~~--~--~---
[Rails] Re: Comparisons between mod_ruby and FastCGI
You are really going to want to take a look at mongrel, thin, or ... my perference ... Passenger/mod_rails. Just type http://modrails.com into your browser window and be amazed. ;) On Nov 28, 11:53 am, Matt <[EMAIL PROTECTED]> wrote: > Hello all, > > I'm a new Ruby on Rails developer who is working on applications for > several different clients using the Ruby on Rails framework. The > question that I've got to pose all of you concerns the differences > between mod_ruby and FastCGI. I'm thinking about trying to get my > webhost to install mod_ruby because it would run lightyears faster, > but there's something I found about mod_ruby that they would probably > take issue with. > > On the Wikipedia article for mod_ruby, it reads: "Its drawback is that > the characteristic sharing of classes among Apache processes is not > safe for multiple applications." However, there is no citation. > > So here's my question - is this a serious safety concern? If so, how > did the developers of mod_php get around this problem? Is there > another, more secure, solution to running ruby apps on a web server > that is faster than mod_ruby? > > Thanks in advance, > Matt --~--~-~--~~~---~--~~ 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-talk@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~--~~~~--~~--~--~---
[Rails] Re: The verdict on Rails scaffolding
> So, the bottom line is that there's nothing fundamentally inept about > it, and it's all up to how you actually use it, right? I would personally agree with that. Your mileage will ALWAYS vary depending on the weather conditions, type of fuel used, people in the car, and cargo inside but ... wait, I got off track there. I tend to use the scaffold to get something up and running and then by the time I am done I have torn it apart and added my own stuff along with getting rid of other stuff. That is all I really use scaffolding for anymore. When I started, I thought it was the only way to go but now I end up writing more custom code than scaffold stuff, but many times I'll end up scaffolding a resource just to make sure I have my bases covered originally. --~--~-~--~~~---~--~~ 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-talk@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~--~~~~--~~--~--~---
[Rails] Re: Developing with Ruby 1.8.2
What is keeping you at Ruby 1.8.2? On Nov 25, 3:05 am, Diego <[EMAIL PROTECTED]> wrote: > Hi all, > > I have to develop a Ruby on Rails web application using Ruby 1.8.2. > > Could you inform me about what are the latest versions of Rails and > RubyGems that should work with Ruby 1.8.2. I am also looking for some > documentation that covers these versions. What I have found so far is > that most of the examples that can be found in internet do not fully > work on Ruby 1.8.2 and Rails 1.1.6 since they are quite old. > > Thanks, > > Diego --~--~-~--~~~---~--~~ 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-talk@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~--~~~~--~~--~--~---
[Rails] Re: Code Review Tool
The only thing that comes to mind would be rcov, but that is for checking testing coverage of your application. Testing is the best way to test the code of your application. On Nov 25, 2:35 am, Karthi kn <[EMAIL PROTECTED]> wrote: > A tool which can test the quality of our all ruby code in our rails > application. > I tried with the gem called "Roodi" to check my code. Is there any other > effective tool for this? > -- > Posted viahttp://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 rubyonrails-talk@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~--~~~~--~~--~--~---
[Rails] Re: Code Review Tool
What do you mean by a "code review tool?" On Nov 24, 10:39 pm, Karthi kn <[EMAIL PROTECTED]> wrote: > Hi, > > I am looking for a code review tool for my ROR application. > Can you suggest something? > > Thanks in advance... > -- > Posted viahttp://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 rubyonrails-talk@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~--~~~~--~~--~--~---
[Rails] Re: Updating select attributes on a profile page
I did a really kludgy fix last night using attr_protected, and I like certain aspects of your idea as well. If I find some time tonight I'll probably take a look at the code again to try and work out a more "beautiful" option for myself. :) Thanks for your help! On Nov 24, 11:53 am, Thorsten Müller <[EMAIL PROTECTED]> wrote: > I use some code like this: > > attr_accessor :new_password > > validates_presence_of :new_password, :on => :create > validates_length_of :new_password, :minimum => 6, :allow_nil => > true, :allow_blank => true, :unless => :new_password.blank? > validates_confirmation_of :new_password > > before_save :set_encrypted_password > > def set_encrypted_password > write_attribute(:password, Client.encrypt_password(@new_password)) > unless @new_password.nil? || @new_password.blank? > end > > def self.encrypt_password(password) > Digest::SHA1.hexdigest("something_random_goes_here_#{password}") > end > > def self.authenticate(email, password) > find_by_email_and_password_and_active(email, encrypt_password > (password), true) > end --~--~-~--~~~---~--~~ 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-talk@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~--~~~~--~~--~--~---
[Rails] Re: rubygems broken
The only time I've run into anything similar is when my internet has either went *kaput* or a firewall setting at work stopped me from downloading any gems automatically. I would maybe check there first. On Nov 24, 8:15 am, expilo <[EMAIL PROTECTED]> wrote: > Hello, > > I have been trying for the last three days on two different debian > linux platforms x386 and amd64 using different rubygems versions > 1.1.1, 1.2.0 and 1.3.1 to update gems on my system. No way! It only > says it's doing a bulk source update, eats all memory and does > nothing. The longest I was waiting was 10 hours. Surely that's enough > to update rails installation with dependencies and a couple of other > gems on a 1Mb cable line? It seems I'll have to learn to live with > manual gem downloads. So my question is: how do you live without > rubygems when you have to? Has anyone any shell scripts that use awk > or sed, tar and wget? I'm sure they would do a better job. I'm close > to start writing one but maybe someone already got something like > this. > > Many thanks for any hints > > Piotr --~--~-~--~~~---~--~~ 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-talk@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~--~~~~--~~--~--~---
[Rails] Re: Single Text_Area for multiple records
Perhaps, and this is just some "brain dump" at the moment, you could set up a separate attribute and then use some Ruby to take that imput and split it so that you can save it as separate attributes. I have no idea how you would do this code wise, but having a text field set up as :input and then attr_accesssor :input and then work from there with some Ruby to split at newlines or with some other kind of operator. On Nov 24, 4:57 am, smfrick <[EMAIL PROTECTED]> wrote: > I have an application I've developed where there is a record of data > which is entered line by line, I've got that working fine. The form > now only has one field, because that's all the data which is > required. I would like to make it simpler by providing a text_area, > and the user would enter a list of values and on submit have the > controller or the model parse the data into records and append them > into the table. I've looked for examples of the correct 'Rails way' > of doing this type of process, but everything looks like a single > record posted. Does anyone know of a Gem or module which will make > this simpler? > > Thanks! --~--~-~--~~~---~--~~ 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-talk@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~--~~~~--~~--~--~---
[Rails] Re: uncaught exception: controls.js requires including script.ac
Looks to me like you need to include the script.aculo.us library, which is found in your public/javascripts/ folder. However, add this to the of your application layout: <%= javascript_include_tag :defaults %> Then make sure that everything is in the javascripts folder. On Nov 24, 1:34 am, Smarty 2k <[EMAIL PROTECTED]> wrote: > hi friends... > > Ajax problem > please help me. > Ajax using delete the record > > Browser Mozilla > > my controller: > > def delete > Book.find(params[:id]).destroy > redirect_to :action =>'book' > end > > my view: > > <%= link_to_remote (image_tag("../images/delete_bt.gif", :border => 0)), > :url =>{ > :controller=>"book", > :action => 'delete', > :id => s.id}, > :update=>"book#{s.id}", > :loading=>"status('book#{s.id}')" > %> > > Error > uncaught exception: controls.js requires including script.aculo.us' > effects.js library > > Line 0 > -- > Posted viahttp://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 rubyonrails-talk@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~--~~~~--~~--~--~---
[Rails] Re: Problem with RubyGems installation
Excellent. I'm still trying to figure out what was missing, but there must have been a dependency missing. I'm glad I could help. On Nov 23, 11:45 pm, Mrmaster Mrmaster <[EMAIL PROTECTED] s.net> wrote: > Everything works now. Thank you soo much for your help. Just a recap I > think the problem was my ruby install the ruby full install command you > gave fixed everything. > -- > Posted viahttp://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 rubyonrails-talk@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~--~~~~--~~--~--~---
[Rails] Re: Problem with RubyGems installation
Make sure you put the dash in between ruby and full. Looking at what you installed, I'm thinking that is not the problem, but it might not hurt. On Nov 23, 10:45 pm, Mrmaster Mrmaster <[EMAIL PROTECTED] s.net> wrote: > Bobnation wrote: > > Did you do an apt-get install ruby-full or just the ruby package? > > > On Nov 23, 10:34 pm, Mrmaster Mrmaster <[EMAIL PROTECTED] > > I've also tried the command you put there and received this message: > > [EMAIL PROTECTED]:/usr/local/lib/site_ruby/1.8$ sudo apt-get > install ruby full > Reading package lists... Done > Building dependency tree > Reading state information... Done > ruby is already the newest version. > ruby set to manually installed. > E: Couldn't find package full > -- > Posted viahttp://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 rubyonrails-talk@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~--~~~~--~~--~--~---
[Rails] Re: Problem with RubyGems installation
Did you do an apt-get install ruby-full or just the ruby package? On Nov 23, 10:34 pm, Mrmaster Mrmaster <[EMAIL PROTECTED] s.net> wrote: > Bobnation wrote: > > This line seems strange: install -c -m 0644 ubygems.rb /usr/local/lib/ > > site_ruby/1.8/ubygems.rb > > > It looks like it is missing an "r" ... but I might just be nitpicking > > here. Have you tried installing an older version (say 1.3.0) and then > > updating to 1.3.1? Also, do you have the development headers for Ruby > > 1.8.7 installed. I know I just did this same installation maybe last > > week, but I might have gone from 1.3.0 to 1.3.1. > > > On Nov 23, 10:23 pm, Mrmaster Mrmaster <[EMAIL PROTECTED] > > I have Ruby 1.8.7 installed and I tried going from 1.3.0 to 1.3.1 and > recieved the same error again. > -- > Posted viahttp://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 rubyonrails-talk@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~--~~~~--~~--~--~---
[Rails] Re: Problem with RubyGems installation
This line seems strange: install -c -m 0644 ubygems.rb /usr/local/lib/ site_ruby/1.8/ubygems.rb It looks like it is missing an "r" ... but I might just be nitpicking here. Have you tried installing an older version (say 1.3.0) and then updating to 1.3.1? Also, do you have the development headers for Ruby 1.8.7 installed. I know I just did this same installation maybe last week, but I might have gone from 1.3.0 to 1.3.1. On Nov 23, 10:23 pm, Mrmaster Mrmaster <[EMAIL PROTECTED] s.net> wrote: > Bobnation wrote: > > What OS are you using? > > > On Nov 23, 7:28 pm, Mrmaster Mrmaster <[EMAIL PROTECTED] > > Actually i just upgraded to Ubuntu 8.10, tried the same steps and still > got the same error message. > > -- > Posted viahttp://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 rubyonrails-talk@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~--~~~~--~~--~--~---
[Rails] Updating select attributes on a profile page
Thanks ahead of time for everyone who will help out with this. I have a profile page for a blog engine I'm writing (because everyone much write a blog engine at some point to learn stuff) and I want to allow members the ability to update their passwords. What I'm having a problem with right now is using the edit page for their profile to update their email and name (which is already populated from the database), which works, but also use it to update the password (which does not ... because it updates the password to blank every time). The situation is this: I am both salting and hashing the password, and using the attr_accessor to grab the password they input on the registration page. However, now when they update their profile, the blank password field generates a new hash and salt and leaves the password blank. Not ideal. I'm wondering how I might be able to selectively update the password if a new password is supplied ... but leave it alone if a password is not supplied. Any help is greatly appreciated! --~--~-~--~~~---~--~~ 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-talk@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~--~~~~--~~--~--~---
[Rails] Re: Problem with RubyGems installation
What OS are you using? On Nov 23, 7:28 pm, Mrmaster Mrmaster <[EMAIL PROTECTED] s.net> wrote: > Hello, > > I am trying to install RubyGems on Ubuntu and i'm having trouble. I've > downloaded rubygems 1.3.1 and when i run the sudo ruby setup.rb command > I get the problem mentioned below. I'd really appreciate if someone can > help me out. > > Thanks > > mkdir -p /usr/local/lib/site_ruby/1.8 > mkdir -p /usr/bin > install -c -m 0644 rbconfig/datadir.rb > /usr/local/lib/site_ruby/1.8/rbconfig/datadir.rb > install -c -m 0644 rubygems.rb /usr/local/lib/site_ruby/1.8/rubygems.rb > install -c -m 0644 rubygems/timer.rb > /usr/local/lib/site_ruby/1.8/rubygems/timer.rb > install -c -m 0644 rubygems/exceptions.rb > /usr/local/lib/site_ruby/1.8/rubygems/exceptions.rb > install -c -m 0644 rubygems/specification.rb > /usr/local/lib/site_ruby/1.8/rubygems/specification.rb > install -c -m 0644 rubygems/rubygems_version.rb > /usr/local/lib/site_ruby/1.8/rubygems/rubygems_version.rb > install -c -m 0644 rubygems/source_index.rb > /usr/local/lib/site_ruby/1.8/rubygems/source_index.rb > install -c -m 0644 rubygems/dependency_installer.rb > /usr/local/lib/site_ruby/1.8/rubygems/dependency_installer.rb > install -c -m 0644 rubygems/user_interaction.rb > /usr/local/lib/site_ruby/1.8/rubygems/user_interaction.rb > install -c -m 0644 rubygems/installer.rb > /usr/local/lib/site_ruby/1.8/rubygems/installer.rb > install -c -m 0644 rubygems/old_format.rb > /usr/local/lib/site_ruby/1.8/rubygems/old_format.rb > install -c -m 0644 rubygems/source_info_cache.rb > /usr/local/lib/site_ruby/1.8/rubygems/source_info_cache.rb > install -c -m 0644 rubygems/command.rb > /usr/local/lib/site_ruby/1.8/rubygems/command.rb > install -c -m 0644 rubygems/command_manager.rb > /usr/local/lib/site_ruby/1.8/rubygems/command_manager.rb > install -c -m 0644 rubygems/indexer.rb > /usr/local/lib/site_ruby/1.8/rubygems/indexer.rb > install -c -m 0644 rubygems/defaults.rb > /usr/local/lib/site_ruby/1.8/rubygems/defaults.rb > install -c -m 0644 rubygems/requirement.rb > /usr/local/lib/site_ruby/1.8/rubygems/requirement.rb > install -c -m 0644 rubygems/validator.rb > /usr/local/lib/site_ruby/1.8/rubygems/validator.rb > install -c -m 0644 rubygems/dependency.rb > /usr/local/lib/site_ruby/1.8/rubygems/dependency.rb > install -c -m 0644 rubygems/server.rb > /usr/local/lib/site_ruby/1.8/rubygems/server.rb > install -c -m 0644 rubygems/commands/update_command.rb > /usr/local/lib/site_ruby/1.8/rubygems/commands/update_command.rb > install -c -m 0644 rubygems/commands/generate_index_command.rb > /usr/local/lib/site_ruby/1.8/rubygems/commands/generate_index_command.rb > install -c -m 0644 rubygems/commands/query_command.rb > /usr/local/lib/site_ruby/1.8/rubygems/commands/query_command.rb > install -c -m 0644 rubygems/commands/server_command.rb > /usr/local/lib/site_ruby/1.8/rubygems/commands/server_command.rb > install -c -m 0644 rubygems/commands/list_command.rb > /usr/local/lib/site_ruby/1.8/rubygems/commands/list_command.rb > install -c -m 0644 rubygems/commands/install_command.rb > /usr/local/lib/site_ruby/1.8/rubygems/commands/install_command.rb > install -c -m 0644 rubygems/commands/stale_command.rb > /usr/local/lib/site_ruby/1.8/rubygems/commands/stale_command.rb > install -c -m 0644 rubygems/commands/pristine_command.rb > /usr/local/lib/site_ruby/1.8/rubygems/commands/pristine_command.rb > install -c -m 0644 rubygems/commands/help_command.rb > /usr/local/lib/site_ruby/1.8/rubygems/commands/help_command.rb > install -c -m 0644 rubygems/commands/check_command.rb > /usr/local/lib/site_ruby/1.8/rubygems/commands/check_command.rb > install -c -m 0644 rubygems/commands/search_command.rb > /usr/local/lib/site_ruby/1.8/rubygems/commands/search_command.rb > install -c -m 0644 rubygems/commands/uninstall_command.rb > /usr/local/lib/site_ruby/1.8/rubygems/commands/uninstall_command.rb > install -c -m 0644 rubygems/commands/cert_command.rb > /usr/local/lib/site_ruby/1.8/rubygems/commands/cert_command.rb > install -c -m 0644 rubygems/commands/build_command.rb > /usr/local/lib/site_ruby/1.8/rubygems/commands/build_command.rb > install -c -m 0644 rubygems/commands/dependency_command.rb > /usr/local/lib/site_ruby/1.8/rubygems/commands/dependency_command.rb > install -c -m 0644 rubygems/commands/unpack_command.rb > /usr/local/lib/site_ruby/1.8/rubygems/commands/unpack_command.rb > install -c -m 0644 rubygems/commands/specification_command.rb > /usr/local/lib/site_ruby/1.8/rubygems/commands/specification_command.rb > install -c -m 0644 rubygems/commands/cleanup_command.rb > /usr/local/lib/site_ruby/1.8/rubygems/commands/cleanup_command.rb > install -c -m 0644 rubygems/commands/sources_command.rb > /usr/local/lib/site_ruby/1.8/rubygems/commands/sources_command.rb > install -c -m 0644 rubygems/commands/fetch_command.rb > /usr/local/lib/site_ruby/1.8/rubygems/commands/fetch_command.rb > install -c -m 0644 rubygems/commands/contents_command.rb > /usr/local/lib/site_ruby/1.8/rubygems/
[Rails] Re: RESTful url not working
"rake routes" really becomes your friend here as you are able to take a look at everything that will work. Trust me, just run it and look over the output to see where you might be going wrong. On Nov 23, 4:03 pm, Ashit Vora <[EMAIL PROTECTED]> wrote: > Hi, > 'm new to Rails. > I tried using _path and _url with link_to helper method but it doesnt > work for me. > > Does anyone know what can be the issue? > my code is > > Hello Rails > <%= flash[:notice] %> > <%= link_to 'Show Blog', posts_url %> > > Post is my controller > > The error 'm getting is > undefined local variable or method `posts_url' for # 0x102b23d> > > 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 rubyonrails-talk@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~--~~~~--~~--~--~---
[Rails] Re: How to create Virtual Host In Apache
I would recommend SliceHost's articles on anything from Ruby on Rails installations to Apache configurations to get a handle on things. http://articles.slicehost.com/ On Nov 21, 6:27 am, Andrey Viana <[EMAIL PROTECTED]> wrote: > If you go to use Passenger (mod_rails) the process is very simple, > just follow these instructions: > > http://www.modrails.com/install.html > > :D > > * Sorry the english, I'm Brazilian > > On Nov 21, 9:18 am, Piyush with Rails <[EMAIL PROTECTED]> wrote: > > > Hi All, > > > I am new to server configurations in apache web server. > > > I want to learn how to create virtual hosts in apache server and run > > configure domains and making domain up. > > > Can anyone guide me here or provide me some useful links ? > > > Thanks, > > > Piyush > > --~--~-~--~~~---~--~~ 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-talk@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~--~~~~--~~--~--~---
[Rails] Re: Can't install rails gem on ibex
Update your gem to 1.3.1 (I recommend from source) and try from there. I know that this link and tutorial is for Hardy, but you can follow the gem install section pretty much verbatim (just grab the newest tar from the site) and be good to go. I used it and am running Rails on Ibex at home both on my web server and desktop. http://articles.slicehost.com/2008/4/30/ubuntu-hardy-ruby-on-rails On Nov 20, 10:23 pm, Joey Marino <[EMAIL PROTECTED]> wrote: > [EMAIL PROTECTED]:~$ cat /etc/issue > Ubuntu 8.10 \n \l > > [EMAIL PROTECTED]:~$ ruby --version > ruby 1.8.7 (2008-08-11 patchlevel 72) [i486-linux] > [EMAIL PROTECTED]:~$ gem --version > 1.2.0 > [EMAIL PROTECTED]:~$ gem install rails > ERROR: While executing gem ... (Errno::ENOENT) > No such file or directory - /var/lib/gems/1.8/cache/rake-0.8.3.gem > > google gives me japanese blog > any ideas? > -- > Posted viahttp://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 rubyonrails-talk@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~--~~~~--~~--~--~---
[Rails] Re: How to read the logs?
I can vouch for this. I haven't been reading logs for long, but I'm getting better the more I do it ... which is bad, because it means I'm making a lot of mistakes. I digress however. It does look like you are missing the RedCloth gem on your production server. On Nov 18, 2:42 pm, Frederick Cheung <[EMAIL PROTECTED]> wrote: > [EMAIL PROTECTED] wrote: > > Can anyone tell me where I can learn how to read and decipher the > > logs? I've done a few google searches and nothing comes up. > > > Specifically, I just uploaded my first app to a production server and > > it doesn't work and I got the following even though it works perfectly > > fine on my development machine: > > I'm not sure there's any substitute for just good old fashioned > experience. In this case there's a missing RedCloth library - I'd > guess you're missing the redcloth gem on your server. > > Fred > > > > > ctionView::TemplateError (uninitialized constant > > Err::Acts::Textiled::ClassMethods::RedCloth) on line #26 of viewer/ > > show.html.erb: > > 23: > > 24: <% else %> > > 25: > > 26: <%= @page.body %> > > 27: > > 28: <% end %> > > /usr/local/lib/ruby/gems/1.8/gems/activesupport-2.1.1/lib/ > > active_support/dependencies.rb:276:in `load_missing_constant' > > /usr/local/lib/ruby/gems/1.8/gems/activesupport-2.1.1/lib/ > > active_support/dependencies.rb:468:in `const_missing' > > /home/admin/book/vendor/plugins/acts_as_textiled/lib/ > > acts_as_textiled.rb:24:in `body' > > /home/admin/book/app/views/viewer/show.html.erb:26:in > > `_run_erb_47app47views47viewer47show46html46erb' --~--~-~--~~~---~--~~ 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-talk@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~--~~~~--~~--~--~---
[Rails] Re: Rails Stability
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 entries about the crappy stability > of mod_php, ASP.NET or any other web technology you can think of. 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 mod_rails (or another config) and maybe even think about running your own virtual server somewhere just for the fun. > --Jeremy > > On Mon, Nov 17, 2008 at 9: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: > >http://geek.littleredstring.com/15-phusions-mod_rails-not-so-hot-acco... > >http://geek.littleredstring.com/32-mod_rails-railsplayground-back-on > > > I am a bit disappointed that Rails has been around for more than 4 years > > and it still needs crutches. I find it a bit hard to go to my IT team > > and ask for something that's unstable or questionable. > > > However, I am willing to consider moving the site somewhere where it's > > more likely to be stable. It was rather interesting to see that > > dreamhost is using mongrel as their webserver even though it seemed like > > they liked mod_rails sometime in late 2007 - early 2008. > > -- > > Posted viahttp://www.ruby-forum.com/. > > --http://jeremymcanally.com/http://entp.com/http://omgbloglol.com > > My books:http://manning.com/mcanally/http://humblelittlerubybook.com/(FREE!) --~--~-~--~~~---~--~~ 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-talk@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~--~~~~--~~--~--~---
[Rails] Re: Rails Stability
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 worked on getting it set up on my server last night. On Nov 16, 9:18 pm, "Jeremy McAnally" <[EMAIL PROTECTED]> wrote: > Sounds like FCGI and RMagick are causing your issues. I'd have to > know a little more exactly what your issues are, but that combination > seems rather deadly in a limited resources environment. > > --Jeremy > > On Sun, Nov 16, 2008 at 8:20 PM, Roland Mai > > > > <[EMAIL PROTECTED]> wrote: > > > I have been away from Rails for a year now, but I have been maintaining > > a site which runs on rails. It's still hosted on textdrive served by > > lighttpd with fastcgi. There's something inherently wrong with fastcgi > > and file uploading. Something about an end of line issue, but mongrel > > kept dieing too. > > > The site keeps on crashing, so I have scripts running that basically > > restart the webservice every so often, but that's just unacceptable for > > more serious work. I can't go to a client and explain what the error > > was. They don't care. > > > The site uses RMagick to resize images and does some basic file > > uploading. I have been in the PHP world for a year now, and I feel that > > PHP is much more stable and portable than Rails. I am at a loss at > > finding any good reasons to choose Rails, other than I like the Ruby > > language. > > > Rails is not as portable as PHP. The sites are generally slow because > > they require a bunch of CPU and shared environments don't have the > > resources. My compromise so far is that Rails is very demanding for > > small projects. > > > Do you know of any reasons that makes Rails well suited for small > > projects and I don't mean microsites or brochure sites. > > -- > > Posted viahttp://www.ruby-forum.com/. > > --http://jeremymcanally.com/http://entp.com/http://omgbloglol.com > > My books:http://manning.com/mcanally/http://humblelittlerubybook.com/(FREE!) --~--~-~--~~~---~--~~ 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-talk@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~--~~~~--~~--~--~---
[Rails] Re: Rails Stability
http://www.modrails.com/ Never had stability issues with Rails I haven't introduced with my own code, but your mileage may vary. On Nov 16, 8:20 pm, Roland Mai <[EMAIL PROTECTED]> wrote: > I have been away from Rails for a year now, but I have been maintaining > a site which runs on rails. It's still hosted on textdrive served by > lighttpd with fastcgi. There's something inherently wrong with fastcgi > and file uploading. Something about an end of line issue, but mongrel > kept dieing too. > > The site keeps on crashing, so I have scripts running that basically > restart the webservice every so often, but that's just unacceptable for > more serious work. I can't go to a client and explain what the error > was. They don't care. > > The site uses RMagick to resize images and does some basic file > uploading. I have been in the PHP world for a year now, and I feel that > PHP is much more stable and portable than Rails. I am at a loss at > finding any good reasons to choose Rails, other than I like the Ruby > language. > > Rails is not as portable as PHP. The sites are generally slow because > they require a bunch of CPU and shared environments don't have the > resources. My compromise so far is that Rails is very demanding for > small projects. > > Do you know of any reasons that makes Rails well suited for small > projects and I don't mean microsites or brochure sites. > -- > Posted viahttp://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 rubyonrails-talk@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~--~~~~--~~--~--~---
[Rails] Re: Logging on Rails 2.2 different than 2.0.2?
Depends, why not have both 2.1.2 and 2.2.1 in there so that you can work on what is going to be coming with 2.2.x? The final version should be coming pretty soon, and the more eyes looking at the current release candidate the better. On Nov 16, 11:10 am, RichardOnRails <[EMAIL PROTECTED]> wrote: > Thanks, Fred, for that clarification. > > And you are right about gems.rubyonrails.org. "gem sources" reports > the I also havehttp://gems.rubyforge.org. > > What do you recommend a senior app developer but a mid-level Rubyist > and junior Railist should have? > > Thanks, again, > Richard > > On Nov 16, 11:46 am, Frederick Cheung <[EMAIL PROTECTED]> > wrote: > > > On Nov 16, 4:00 pm, RichardOnRails > > > <[EMAIL PROTECTED]> wrote: > > > Hi, > > > > I recently saw some blogs suggesting the 2.2.0 might not yet be the > > > "released version", though I doubt that because IMHO the gem > > > installer wouldn't have included it among the available Rails > > > versions. Maybe the articles I saw were outdated. True? > > > 2.2.0 is 2.2RC1 (and 2.2.1 is the second release candidate) so those > > blogs are accurate in that neither of those versions are the final > > version of 2.2. You would only get those versions if you had added > > gems.rubyonrails.org to your list of gem sources. > > > Fred --~--~-~--~~~---~--~~ 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-talk@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~--~~~~--~~--~--~---
[Rails] Re: ROR switcher asks "Does ROR offer CRUD form (admin interfaces) auto-generation for databases?"
On Nov 11, 11:13 pm, "Micheal Cooper" <[EMAIL PROTECTED]> wrote: > I am currently using a very early framework called ERW, and I getting > into Ruby so that I can recreate (with paid help) a very large college > administration db app in Rails. Until relatively recently, I was going > to do this in Django, and one reason for the choice was Django's > excellent feature of automatically generating the basic CRUD forms > (Django calls them admin forms) for a newly-created database. The > framework I am using now also has this feature, though it is overly > complex and difficult to maintain. The current scaffold generator is RESTful, and builds migrations based on the input you give to the generator. If you are looking to set up your database and then have a generator build the CRUD forms from that database scheme, then you'll want to look at the ActiveScaffold seen in a prior comment. > I want to know if there is a feature in or add-on to Rails that looks > at the database and creates customizable CRUD interfaces for all > tables, including selectable foreign keys and filters, etc. Ideally, > the forms would be scripts that can be filled-out and customized and > only need to be recreated when the database has been changed. > > ERW's admin interface is PHP code that dynamically creates the forms > when you call the script, and customization requires precise and > redundant coding because generic scripts are used to create all the > CRUD forms. For example, all admin list interfaces are done by > list.php, so getting an admin list for table people requires going to > 'list.php?table=people'. > > I am hoping that ROR has a better way. > > -- > Micheal Cooper > Miyazaki, Japan (GMT+9, no DST) --~--~-~--~~~---~--~~ 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-talk@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~--~~~~--~~--~--~---
[Rails] Re: Is Rails Scaffolding Production Ready
On Nov 11, 9:53 pm, Ar Chron <[EMAIL PROTECTED]> wrote: > When one of my users asks for a new "feature" that involves a new model > and all the trimmings, I routinely scaffold up the prototype, do as > little code as I can to make it fit in with the application, then bring > them in for a test drive on my dev machine. > > The scaffolded layouts don't match the app, and there's no styling, but > it assures that I interpreted their concept correctly. > > Then it's time to perform surgery on all the scaffolded code and meld > the new bits into the production application. > > Sooo, I wouldn't say that raw scaffolded code is production ready, but > it is certainly a fast track for prototyping. > > -- > Posted viahttp://www.ruby-forum.com/. That's actually a fantastic way of looking at it. --~--~-~--~~~---~--~~ 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-talk@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~--~~~~--~~--~--~---
[Rails] Re: Is InstantRails still a viable way to start with Rails?
> My advice: > If you just want to play around with rails a little bit but never > intend on doing any "real" work with it then IR is fine. If you're > getting started on a project that you plan on eventually deploying to > a server somewhere, go through the steps of getting everything > installed properly on your box. I would take it a step farther and say if you are going to do some "real work" (what is real work anyway?), then I would recommend trying to get an install up on a Linux box somewhere. When you deploy, it will more than likely be to a Linux-based server, so it will save you many headaches if you have at least one box where you can develop as close to the deployment environment as possible. Just a thought. --~--~-~--~~~---~--~~ 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-talk@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~--~~~~--~~--~--~---
[Rails] Re: Is Rails Scaffolding Production Ready
I'm not the best person to answer this, but I would caution you to "be careful" nonetheless. Sometimes it is better to put in the work in order to understand exactly how things are pieced together. Just my thoughts. On Nov 11, 11:44 am, "Chas Lemley" <[EMAIL PROTECTED]> wrote: > Is scaffolding in Rails production ready? I've read a few opinions on this, > but most were referring to the original style of scaffolding found in > rails. > > Because scaffolding now creates the controller, models, views for me is > there anything I need to watch out for when trying to build upon this to > arrive at a production-ready product? > > Thanks for the help. > > Chas --~--~-~--~~~---~--~~ 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-talk@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~--~~~~--~~--~--~---
[Rails] Re: Migration File
Nope, nothing wrong, just a change. Glad we can be of some help. On Nov 10, 9:07 pm, Bert Ameche <[EMAIL PROTECTED]> wrote: > Rick wrote: > > It's a date/time stamp. I guess it's guaranteed to be unique - as > > long as you ensure that you timeofday clock is in good shape. > > > Rick > > > On Nov 10, 8:42 am, Bert Ameche <[EMAIL PROTECTED]> > > Thank you very much, Rick and Bobnation! I thought I did something > wrong. > -- > Posted viahttp://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 rubyonrails-talk@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~--~~~~--~~--~--~---
[Rails] Re: Should I get Agile Web Development with Rails (Pragmatic Programmers) Book?
On Nov 11, 8:31 am, Nicolas Alpi aka Spyou <[EMAIL PROTECTED]> wrote: > On their website you can have a preorder of the Hard Cover book, and > waiting for it, you'll the book on pdf (and you can regenerate it at > every update). > > It works very well ;) > > Nic Correct, you can get the Beta PDF (which I think is pretty complete) and just follow along and get a "dead tree" copy when it is released. You also might want to pick up Simply Rails 2 as a good place to start, and also The Art of Rails as another good book. Both, I think, cover Rails 2.x pretty well. I was able to use Simply Rails 2 with 2.1.1, so I hope that helps. > > On Nov 11, 12:20 pm, bena <[EMAIL PROTECTED]> wrote: > > > I'm an experienced programmer, working for a lot of years in the > > industry, and have been learning Ruby recently. I wondered if it was a > > good idea to buy the Agile Web Development with Rails (Pragmatic > > Programmers) book, or should I wait for an update for 2.0? > > > TIA > > > Ben --~--~-~--~~~---~--~~ 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-talk@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~--~~~~--~~--~--~---
[Rails] Re: Migration File
On Nov 10, 7:45 pm, Rick <[EMAIL PROTECTED]> wrote: > It's a date/time stamp. I guess it's guaranteed to be unique - as > long as you ensure that you timeofday clock is in good shape. > > Rick That's the truth. It is meant to try and help with distributed development teams having duplicate numbers for migration files. > On Nov 10, 8:42 am, Bert Ameche <[EMAIL PROTECTED]> > wrote: > > > All of the books I have show the migration file naming convention is > > 001, 002, etc > > > When I ran script/generate model, the migration file was named: > > 20081110174511_create_users.rb > > > Why does it have this complex number instead of 001? Is there a way to > > redo this and get the simpler name? > > -- > > Posted viahttp://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 rubyonrails-talk@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~--~~~~--~~--~--~---
[Rails] Re: (Newbie) routing question
Looking at the error message, it seems to be saying that user_id is nil ... which tells me that you don't have a user set for that photo and it can't generate the URL without knowing the id of the user. On Oct 28, 5:48 am, Vahagn Hayrapetyan <[EMAIL PROTECTED] s.net> wrote: > Hi, I have a question about routing and nested resources. I have an app > with Photos that belong to Users via a many2one relationship. The URL: > > http://localhost:3000/photos > > lists all photos (from all users). Clicking on a random photo from this > listing should send one to f ex: > > http://localhost:3000/users/2/photos/10 > > Because I have this in my routes.rb: > > map.resources :users, :member => { :enable => :put } do |users| > users.resources :photos, :name_prefix => 'user_', > :controller => 'user_photos', > :member => { :add_tag => :put, :remove_tag > => :delete } > end > > However when I loadhttp://localhost:3000/photosI get this error > message: > > user_photo_url failed to generate from {:controller=>"user_photos", > :action=>"show", :user_id=>nil, :id=># nil, body: nil, created_at: "2008-10-27 14:26:32", etc > > Extracted source (around line #2): > > 1: > 2: <%= link_to image_tag(photo.public_filename('thumb')), > user_photo_path(:user_id => photo.user, :id => photo) %> > 3: > > The above partial, _photo.rhtml, is what causes the error. > > This code has worked fine up until I refactored it to function with > will_paginate instead of classic_pagination. I haven't touched the > routing declarations or the _photo.rhtml partial. > > Any help will be appreciated! > > / Vahagn > -- > Posted viahttp://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 rubyonrails-talk@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~--~~~~--~~--~--~---
[Rails] Re: Future of Ruby as well as Rails
I think the future is bright ... but I'm an idealist. :) On Oct 11, 3:42 am, Sijo Kg <[EMAIL PROTECTED]> wrote: > Hi > while searching through the old posts I got this very old post.. > > http://www.ruby-forum.com/topic/68101 > Since all its answers are old I am posting my concern as seperate > > But may I ask the source question again? > I love Ruby - But how bright is Ruby's Future? > This is just to know only..I am from India...Why I am asking this is in > India the big corporates using rails is very few atleast for now .dont > know what will happen in future I am saying this of the job postings by > big IT companies on Ruby/Rails category. compare to Java and PHP? So may > I know the current status of Ruby as well as rails? I expect a clear > answer ..I dont know what is happening in other countries .I would like > to know the future of Ruby and Rails especially in the job market > > Thanks in advance > Sijo > -- > Posted viahttp://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 rubyonrails-talk@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~--~~~~--~~--~--~---
[Rails] Re: http://localhost:3000/index.html does not open my home page
Check your config/routes.rb and read how to set your root route in there and then delete the standard index.html page and you should be set to go. On Oct 11, 10:39 am, Pepe Sanchez <[EMAIL PROTECTED]> wrote: > Hi all > > How can I change the setup in order to open my home page "index.html" > located inside the Public folder when I typehttp://localhost:3000/index.html > > thanks > -- > Posted viahttp://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 rubyonrails-talk@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~--~~~~--~~--~--~---
[Rails] Re: Model.create(!) doesn't add to database, no errors..
Could you post your code so we can take a look at the actual actions? On Oct 7, 11:33 am, rpag <[EMAIL PROTECTED]> wrote: > Hi, > > I am trying to get form submitted data be submitted to my database, > however not matter what I try it won't work. in script/console > Model.create(args) adds to the database just fine. > > pastie is here > > I've tried .create(!), .save after it, and Model.new in the action > index. > Thanks for any help --~--~-~--~~~---~--~~ 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-talk@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~--~~~~--~~--~--~---
[Rails] Re: any advice re best way to make money as a RoR developer in your spare time???
I guess the main thing would be to somehow keep track of what you have done and then where you are planning on going from there. The main thing is to let this be fun so that you WANT to do it, and not to let it affect the rest of your life. I would recommend maybe trying out some of 37signals' products to see which one might work the best for you. I use Basecamp with another company I do some web programming for, but I use Backpack for myself for my independent web stuff and all of my Ruby on Rails work as well. I keep a page for each project and then always keep little reminders of what I was thinking last time. It has helped me take a day or two off without missing a beat. On Oct 6, 6:18 am, Phlip <[EMAIL PROTECTED]> wrote: > Greg Hauptmann wrote: > > Any advice on, realistically, what's a reasonable approach to try to > > make some money in ones spare time (after a 9-5pm job) using one's Ruby > > on Rails skills? So therefore in my case I may only have 5-10 hours a > > week available, and these would be scattered throughout the week. > > In terms of a sustainable pace, hardcore programming after hours tends to > bring > down your day job. > > If it's not Ruby, hop! > > -- > Phlip --~--~-~--~~~---~--~~ 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-talk@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~--~~~~--~~--~--~---
[Rails] Re: mac vs windows - why is windows soooo slow?
On Oct 5, 7:52 pm, Aryk Grosz <[EMAIL PROTECTED]> wrote: > Guys, > > Thanks a TON for your input. Now I know Im not alone. Im going to look > into developing on mac instead of windows just because of this speed > issue. You would not be alone in that either. Many people develop Rails on Macs, I did for a while until finances came into play, but you will not be disappointed. > Would I be right in saying that mac's are on par in speed as unix > running RoR? Thats been my observation, especially with beefier mac > desktops. Yes, I believe you would. Enjoy, but I would recommend maybe trying out one of the newer Linux desktops as well. There might be a learning curve, but it would at least give you a free alternative to try out before taking the plunge. --~--~-~--~~~---~--~~ 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-talk@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~--~~~~--~~--~--~---
[Rails] Re: zena CMS first public release !
Fun, source code to read! On Oct 6, 6:09 am, "[EMAIL PROTECTED]" <[EMAIL PROTECTED]> wrote: > looks impressive. > I am looking foward to testing the CMS. > > regards > svend > > On Oct 6, 10:09 am, "Gaspard Bucher" <[EMAIL PROTECTED]> wrote: > > > After 3 years of work in my cave, I am happy to go out in the sunlight > > to announce the first public beta release of zena ! > > > In a few words: > > > Zena is a CMS based on ruby on rails with a very advanced xhtml based > > templating language called zafu. Sites have been running in production > > mode for nearly 2 years now, so it's quite stable (more then 1340 unit > > tests). > > > One of the most important architecture aspects of this CMS is that it > > is based on Single Table Inheritance with the ability to create custom > > classes from the web frontend. > > > More information on this release in this post from the > > blog:http://zenadmin.org/473 > > > Videos:http://zenadmin.org/426 > > > I hope you enjoy... > > > Gaspard --~--~-~--~~~---~--~~ 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-talk@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~--~~~~--~~--~--~---
[Rails] Re: mac vs windows - why is windows soooo slow?
I've had much the same experience. I won't even do development work on my work box anymore because I am forced to use Windows XP there. I have a cheap IBM ThinkPad I do most of my developer work with and I have Ubuntu 8.04.1 loaded onto it. On Oct 5, 11:04 am, Fernando Perez <[EMAIL PROTECTED]> wrote: > Pratik Naik wrote: > > where is it said that > > I think he is talking about his own experience, not about the book. > > My personal tests: running rake or any ruby is much faster on my old > iBook with Tiger than on my Windows XP box with an Intel Core2Duo E6300. > I won't even talk about running autotest on my windows box. "Innovation" > as they call it... > -- > Posted viahttp://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 rubyonrails-talk@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~--~~~~--~~--~--~---
[Rails] Re: mac vs windows - why is windows soooo slow?
Someone with far more technical knowledge of the inner workings of both Windows and *nix would have to speak, but most people I have spoken to recommend doing development on even a virtual Linux box because many of the tools you will use "just work" better on Linux than they do on Windows. On Oct 4, 2:44 pm, Frederick Cheung <[EMAIL PROTECTED]> wrote: > On Oct 4, 8:39 pm, Aryk Grosz <[EMAIL PROTECTED]> > wrote: > > > I don't really want this to turn into a heated discussion, Im just > > trying to figure out if Im somehow missing any dependencies or tweaks. > > > I have a very beef dual dual-core computer with 4 gbs of ram, 500gb, and > > a really good video card. > > > Yet, when Im starting/stopping my development server, or clicking > > through controller actions, it is very slow. > > > To give you an idea of how slow, my coworker has an equivalent mac > > desktop, which runs things about THREE times fast, thats including > > migrations, bootup, controller actions. > > > Is there something about the ruby interpreter on windows that makes > > things so slow. > > Ruby is known for being slower on window than on *nix like platforms. > No idea why. > > Fred > > > Aryk > > -- > > Posted viahttp://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 rubyonrails-talk@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~--~~~~--~~--~--~---
[Rails] Re: undefined method `merge' for "/":String
I'd love to read it. Looking forward to it. On Oct 3, 1:22 am, infinteVerve <[EMAIL PROTECTED]> wrote: > Nevermind, Just fixed it. > I will post the solution tomorrow, for anyone else tackling similar > issues. > > On Oct 2, 11:34 pm, infinteVerve <[EMAIL PROTECTED]> wrote: > > > issue #1. I'm a newb. > > > So, I'm trying to set up a calendar of lessons using the > > WeekViewHelper snippet found > > here:http://snippets.dzone.com/posts/show/5206(veryslightly altered). The > > problem only occurs when I try to set the :url option. Without it > > works fine, except I haven't been able to (can't figure it out) create > > links to go to the next or previous weeks. > > > Any help, or suggestions are greatly appreciated, or if you know of a > > different way to go about it. > > > The code for the various files are posted below. "start_date" and > > "end_date" are columns in the table "lessons", while "starts_at" and > > "ends_at" are options for the helper. > > > WEEK_VIEW_HELPER.RB: > > > require 'date' > > > # Author: Josh Adams > > # This helper is based on CalendarHelper. > > # WeekViewHelper allows you to draw a databound week view calendar > > with fine-grained CSS formatting > > module WeekViewHelper > > VERSION = '0.0.1' > > > # Returns an HTML week-view calendar. In its simplest form, this > > method generates a plain > > # calendar (which can then be customized using CSS) for a given > > span of days. > > # However, this may be customized in a variety of ways -- changing > > the default CSS > > # classes, generating the individual day entries yourself, and so > > on. > > # > > # The following options are required: > > # :starts_at > > # :ends_at > > # > > # The following are optional, available for customizing the > > default behaviour: > > # :table_class => "week-view" # The class for the > > tag. > > # :day_name_class => "dayName" # The class is for the > > names of the days, at the top. > > # :day_class => "day" # The class for the > > individual day number cells. > > # This may or may not > > be used if you specify a block (see below). > > # :show_today => true # Highlights today on > > the calendar using the CSS class 'today'. > > # # Defaults to true. > > # :previous_span_text => nil # Displayed left if > > set > > # :next_span_text => nil # Displayed right if > > set > > # > > # For more customization, you can pass a code block to this > > method, that will get two argument, both DateTime objects, > > # and return a values for the individual table cells. The block > > can return an array, [cell_text, cell_attrs], > > # cell_text being the text that is displayed and cell_attrs a hash > > containing the attributes for the tag > > # (this can be used to change the 's class for customization > > with CSS). > > # This block can also return the cell_text only, in which case the > > 's class defaults to the value given in > > # +:day_class+. If the block returns nil, the default options are > > used. > > # > > # Example usage: > > # week_view(:starts_at => (Date.today - 5), :ends_at => > > Date.today) # This generates the simplest possible week-view. > > # week_view(:starts_at => (Date.today - 5), :ends_at => > > Date.today, :table_class => "calendar_helper"}) # This generates a > > week-view, as > > > # > > # before, but the 's class > > > # > > # is set to "calendar_helper". > > # week_view(:starts_at => (Date.today - 5), :ends_at => > > Date.today) do |s| # This generates a simple week-view, but gives > > special spans > > # if listOfSpecialSpans.include?(s) # (spans that are > > in the array listOfSpecialSpans) one CSS class, > > # ["", {:class => "specialSpan"}] # "specialSpan", and > > gives the rest of the spans another CSS class, > > # else # "normalSpan". > > You can also use this to highlight the current time differently > > # ["", {:class => "normalSpan"}] # from the rest of > > the days, etc. > > # end > > # end > > # > > # For consistency with the themes provided in the calendar_styles > > generator, use "specialSpan" as the CSS class for marked days. > > # > > def week_view(options = {}, &block) > > raise(ArgumentError, "No start date given") unless > > options.has_key?(:starts_at) > > raise(ArgumentError, "No end date given") unless options.has_key? > > (:ends_at) > > span = (options[:ends_at] - options[:starts_at]).to_i # Get the > > number of days represented by the span given > > dates = (options[:starts_at]..options[:ends_at]) > > start_time = 13 > > end_time = 21 > > time_range = (start_
[Rails] Re: Help me , which book is good for ror 2.1.1
Simply Rails 2, while using 2.0.2, is still quire relevant for 2.1.1. I just worked my way through it again to brush up on some things and everything "just worked." Also, check out Agile Web Development with Rails v.3 at http://pragprog.com. They have a beta PDF available which is quite good as well. On Oct 3, 12:14 am, "[EMAIL PROTECTED]" <[EMAIL PROTECTED]> wrote: > Iam new to ruby on rails . plz guide me how to start ror 2.1.1, please > send me the link. --~--~-~--~~~---~--~~ 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-talk@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~--~~~~--~~--~--~---
[Rails] Re: New to Rails.
Have fun, read lots, and ask questions. SQLite3 is a wonderful way to get started with things. On Oct 2, 3:16 pm, "Zack K." <[EMAIL PROTECTED]> wrote: > I just downloaded the new version of rails which has SQLite with it, > any tips on getting things set up? > > On Oct 2, 1:44 pm, blasterpal <[EMAIL PROTECTED]> wrote: > > > The prefpane is broken in 10.5 last I check. For now just search for > > "mysql_safe" and google how to start from command line. The real issue > > here is OSX is not like Linux AT ALL in how it starts daemons. And > > some of the reading you might find on Linux simply won't apply. > > > My real recommendation to people getting into Rails is you HAVE to > > have some sysadmin comfort. Rails is NOT a a RAD in the sense of the > > 1990's (i'm showing my age :)). Don;t take this as a condemnation. I > > am glad you are getting into Rails Zack. The primary issue with using > > packages is that when they don't work or something about your system > > is broken, you have no recourse. > > > I would recommend the following before you continue ANY further: > > > *download XCode 3 from Apple. and install > > *run apple updates. > > *ONLY use packages that say they work for 10.5. DO NOT assume 10.4 > > packages will work(they might). Apple has made some changes to 10.5 > > that I can't recall. But you are going to say yourself trouble if you > > at least consider my warning. > > > Secondly, > > If you are not ready to take the jump into downloading source. Then > > investigate using Fink or DarwinPorts. I have found these invaluable > > when I needed something running quickly (they do some of the compiling > > work for you). > > > Good luck. > > Hank > > > On Oct 2, 12:55 pm, "Zack K." <[EMAIL PROTECTED]> wrote: > > > > I installed the .prefpane for System Preferences and it and always > > > crashes when i try to start the server the prefpane crashes, any > > > ideas? > > > > On Oct 2, 12:47 pm, Frederick Cheung <[EMAIL PROTECTED]> > > > wrote: > > > > > On 2 Oct 2008, at 17:27, blasterpal wrote: > > > > > > 10.5 changed some things. I've used this a couple of times already to > > > > > do from source (which is the most flexible and best for understanding > > > > > and learning): > > > > > >http://hivelogic.com/articles/2007/11/installing-mysql-on-mac-os-x > > > > > As far as mysql goes, I've never done anything fancier than > > > > downloading the prebuilt packages from mysql > > > > > Fred > > > > > > H > > > > > > On Oct 2, 10:14 am, "Zack K." <[EMAIL PROTECTED]> wrote: > > > > >> I have locomotive on OS X 10.5 and i can't get mySQL to install > > > > >> right. > > > > >> That's my main problem. > > > > > >> On Oct 2, 9:11 am, Shandy Nantz <[EMAIL PROTECTED]> > > > > >> wrote: > > > > > >>> Zack K. wrote: > > > > Can someone help me get started, i've been messing around with it > > > > lately, and i also learn some Ruby to understand RoR somemore. I've > > > > been trying to get it too work for awhile, but my problem is that i > > > > can NEVER get mySQL to install in anyway, shape, or form. It's > > > > really > > > > aggravating, so if anyone has anytips, that would be helpful! > > > > > -Zack > > > > > >>> What are you trying to install? Instant Rails? Is there any kind of > > > > >>> error that is being thrown? > > > > >>> -- > > > > >>> Posted viahttp://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 rubyonrails-talk@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~--~~~~--~~--~--~---
[Rails] Re: New to Rails.
I'm curious as to the choice for Locomotive and not using Rails just within Mac OS X itself. On Oct 2, 9:14 am, "Zack K." <[EMAIL PROTECTED]> wrote: > I have locomotive on OS X 10.5 and i can't get mySQL to install right. > That's my main problem. > > On Oct 2, 9:11 am, Shandy Nantz <[EMAIL PROTECTED]> > wrote: > > > Zack K. wrote: > > > Can someone help me get started, i've been messing around with it > > > lately, and i also learn some Ruby to understand RoR somemore. I've > > > been trying to get it too work for awhile, but my problem is that i > > > can NEVER get mySQL to install in anyway, shape, or form. It's really > > > aggravating, so if anyone has anytips, that would be helpful! > > > > -Zack > > > What are you trying to install? Instant Rails? Is there any kind of > > error that is being thrown? > > -- > > Posted viahttp://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 rubyonrails-talk@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~--~~~~--~~--~--~---
[Rails] Re: New to Rails.
Windows, Mac, Linux, OpenSolaris? On Oct 2, 12:33 am, "Zack K." <[EMAIL PROTECTED]> wrote: > Can someone help me get started, i've been messing around with it > lately, and i also learn some Ruby to understand RoR somemore. I've > been trying to get it too work for awhile, but my problem is that i > can NEVER get mySQL to install in anyway, shape, or form. It's really > aggravating, so if anyone has anytips, that would be helpful! > > -Zack --~--~-~--~~~---~--~~ 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-talk@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~--~~~~--~~--~--~---
[Rails] Re: Rails 2.0 book
I'll vouch for "The Rails Way" as well. Excellent resource once you know your way around a little better. On Sep 29, 10:59 am, CPerry <[EMAIL PROTECTED]> wrote: > Another good book that I simply couldn't live without is "The Rails > Way" by Obie Fernandez. It covers Rails 2.x and is an excellent book > to have at your side when building an app. > > --Cory > > On Sep 29, 1:35 am, Jae Lee <[EMAIL PROTECTED]> wrote: > > > Can anyone recommend any book for Rails 2.0? > > I have read "Agile Web Development with Rails - 1st" and i loved this > > book. > > > I wonder if there is any good guidance for Rails 2.0. > > > Thank you! > > -- > > Posted viahttp://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 rubyonrails-talk@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~--~~~~--~~--~--~---
[Rails] Re: Rails 2.0 book
Simply Rails 2 or the 3rd Edition of Agile Web Development (which you can find the beta PDF on pragprog.com). On Sep 29, 12:35 am, Jae Lee <[EMAIL PROTECTED]> wrote: > Can anyone recommend any book for Rails 2.0? > I have read "Agile Web Development with Rails - 1st" and i loved this > book. > > I wonder if there is any good guidance for Rails 2.0. > > Thank you! > -- > Posted viahttp://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 rubyonrails-talk@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~--~~~~--~~--~--~---
[Rails] Re: Which version of Rails?
Definitely move to the latest, and grab a copy of Simply Rails 2 if you are interested. A great, easy read which should guide you rather well through some of the changes between Rails 1.x and 2.x. On Sep 29, 7:43 am, Jae Lee <[EMAIL PROTECTED]> wrote: > Hello all, > > Which version of Rails do you recommend if I start a new project using > RoR? > I studied RoR with Agile Web Development with Rails (1st edition) last > year, and found that there is new version 2.x out there - but, it was > very hard for me to find any book for Rails 2.0. > > Do I have to stick with 1.x version of Rails? > Also, I wonder if the rails hosting companies do support the latest > version of Rails as well. > > I thank you for your advice in advance. > -- > Posted viahttp://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 rubyonrails-talk@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~--~~~~--~~--~--~---
[Rails] Re: controller issue with plurals
Have you tried map.resources :main? On Sep 21, 10:50 pm, Grayson Piercee <[EMAIL PROTECTED] s.net> wrote: > Ryan Bigg wrote: > > How are you mapping it in the routes.rb? > > map.resource :main > -- > Posted viahttp://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 rubyonrails-talk@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~--~~~~--~~--~--~---
[Rails] Re: Agile Web Development with Rails Second vs Third edition
A good idea. The Beta PDF is available straight from PragProg ... you can give that a shot as well. On Sep 20, 6:40 am, "Commander Johnson" <[EMAIL PROTECTED]> wrote: > You can learn rails with v2, but some things like migration file names and > especially dynamic scaffolding will be different. If you don't want to remap > everything in your brain, get the 3rd edition eBook. > > On Thu, Sep 18, 2008 at 8:44 PM, Guillermo Acilu <[EMAIL PROTECTED]>wrote: > > > > > Hello guys, > > > I am starting with Rails and I have bought the book "Agile Web > > Development with Rails Second". The book is very good but I've found > > out already that there are some differences between rails 1.2 and the > > current 2.1. > > > Is it the old edition good enough to learn rails? or should I try to > > buy a book based on rails 2.1? > > > Thanks in advance, > > > GA --~--~-~--~~~---~--~~ 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-talk@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~--~~~~--~~--~--~---
[Rails] Re: controller issue with plurals
What methods do you have in your MainsController? On Sep 18, 12:58 pm, Grayson Piercee <[EMAIL PROTECTED] s.net> wrote: > I have a controller named main and it's mapped through routes.rb > > when I link to "main_path" I get this error: > > uninitialized constant MainsController > > I tried creating a MainsController and mapping that but didn't seem to > help. > > GP > -- > Posted viahttp://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 rubyonrails-talk@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~--~~~~--~~--~--~---
[Rails] Re: Agile Web Development with Rails Second vs Third edition
All good recommendations, but I would like to toss in Simply Rails 2 as well as a good place to start. So far, I've been working through the book using Rails 2.1.1 and have not had any problems so far. On Sep 18, 10:00 pm, "Conrad Taylor" <[EMAIL PROTECTED]> wrote: > On Thu, Sep 18, 2008 at 5:39 PM, jjburka <[EMAIL PROTECTED]> wrote: > > > I would recommend 'The Rails Way' by Obie Fernandez I found that much > > more helpful than the Agile Web Dev book > > > On Sep 18, 5:07 pm, Robert Walker <[EMAIL PROTECTED]> > > wrote: > > > The "Beta Book" for Third Edition is suppose to be keep up with the > > > latest Rails version, which will likely be at least version 2.2 by the > > > end of the beta cycle. > > > > If you use the Second edition it is recommend to use the version of > > > Rails used in the book, or the tutorial code will have problems and > > > you'll have to deal with that instead of actually learning Rails. > > > > Guillermo Acilu wrote: > > > > Hello guys, > > > > > I am starting with Rails and I have bought the book "Agile Web > > > > Development with Rails Second". The book is very good but I've found > > > > out already that there are some differences between rails 1.2 and the > > > > current 2.1. > > > > > Is it the old edition good enough to learn rails? or should I try to > > > > buy a book based on rails 2.1? > > > > > Thanks in advance, > > > > > GA > > Hi, I would recommend Agile Web Development with Rails 3rd Edition as a > starting > point. You should at least complete the construction of the demo > application. Then > I would take a look at the following books: > > "The Rails Way" by Obie Fernandez - an excellent reference on Rails 2.0 but > I'm looking forward to an update covering Rails 2.2 > "Advanced Rails Recipes" by Mike Clark and the Rails community - an > excellent cookbook (i.e. problem/solution format) > > Lastly, you have the people here to assist you along the way. > > Good luck, > > -Conrad --~--~-~--~~~---~--~~ 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-talk@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~--~~~~--~~--~--~---