[Rails] SQLite - show html from entry

2010-06-18 Thread Eric Yen
around this? Thank you, Eric -- You received this message because you are subscribed to the Google Groups Ruby on Rails: Talk group. To post to this group, send email to rubyonrails-t...@googlegroups.com. To unsubscribe from this group, send email to rubyonrails-talk+unsubscr

[Rails] Re: rake db:create uninitialized constant Mysql::Error

2010-06-01 Thread Eric Platon
. Given that this PPC64 machine is my production server, a simple conditional to choose between gem or require may be sufficient, waiting for a proper fix. I hope this can help you, but I have a rare architecture these days... Not sure it is applicable directly. Eric On Apr 12, 3:04 pm, Michael

[Rails] CAS Authentication

2010-05-06 Thread Eric B.
So I have recently tried authenticating to a cas server for a project, and every time I try to access my cas server it returns SSL_connect returned=1 errno=0 state=SSLv3 read server certificate B: certificate verify failed Now I am using the CAS gem found here

[Rails] Re: id upper bounds

2010-04-19 Thread Eric B.
Franz Strebel wrote: last_id = MyModel.find(:first, :order = 'id desc').id @Franz Thanks this worked great well kinda, I'm confused on why there is the '.id' at the end also how would I limit this to give me say the first 3 from the back of the list instead of :all or :first and :limit = 3

[Rails] Re: Re: id upper bounds

2010-04-19 Thread Eric B.
To all that have helped out thank you I do have what i wanted to accomplished though it may not be super efficient it does what i need with no repeats from my tests here is what i have done. index.html.erb %

[Rails] id upper bounds

2010-04-18 Thread Eric B.
I am new to both ruby and rails and a recent project I am trying has got me working on it. I am trying to find a nice easy lightweight way to find the last 'id' in a mysql database so I can take it and use it as the upper bound in a random number generator. My problem is that I haven't found an

[Rails] Can't Convert Symbol into Integer

2010-04-10 Thread Eric Powell
I must have really screwed something up big time. I was trying to modify SortHelper to work on multiple columns and now I can't get anything to work even though I reverted all my changes. I keep getting the error: can't convert Symbol into Integer C:/Users/Eric Powell/Documents/ruby/my1fnc/app

[Rails] Re: Can't Convert Symbol into Integer

2010-04-10 Thread Eric Powell
Frederick Cheung wrote: On Apr 10, 3:25�pm, Eric Powell li...@ruby-forum.com wrote: I must have really screwed something up big time. �I was trying to modify SortHelper to work on multiple columns and now I can't get anything to work even though I reverted all my changes. Looks like

[Rails] Re: One-time script to update 1000s of values in a single column in a table: nil error?

2010-03-17 Thread Eric Artzt
it looks like you are trying to strip a leading space from each strength value if its not nil. something like stocks = Stock.find(:all, :conditions = '(strength IS NOT NULL) AND (strength != )') would give you all the stocks values with non-blank values. So you can skip a lot of your testing

[Rails] Re: rerender a page if validation fails

2010-03-17 Thread Eric Artzt
Your error case rendered the edit template... pretty standard. The path was called on a POST (the update). There is no corresponding GET version of that path. So when you try to go there in the browser you get an error. On Mar 17, 10:34 pm, Tom Mac li...@ruby-forum.com wrote: Hi    I have in

Re: [Rails] mysql on mongrel vs apache

2010-03-13 Thread Eric Bolden
It looks like you are running out of memory (RAM) and disk-swapping is accounting for the difference in times. On Mar 13, 2010, at 3:43 AM, Ease Bus wrote: Thanks all. The amount of data on the Ubuntu staging server is a little bit more than the data on my Leopard laptop. So the slight

[Rails] Weird install problems

2010-03-06 Thread Eric B.
I am new to RoR, and I am just starting out, but I am having massive problems doing what should be a painless install. I am running a windows machine and I have ruby installed as well as gems. When I try to do the command gem install rails I get c:\Ruby19gem install rails ERROR: While executing

[Rails] Re: Weird install problems

2010-03-06 Thread Eric B.
Eric B. wrote: I am new to RoR, and I am just starting out, but I am having massive problems doing what should be a painless install. I am running a windows machine and I have ruby installed as well as gems. When I try to do the command gem install rails I get c:\Ruby19gem install rails

[Rails] reCAPTCHA headache

2010-02-07 Thread Eric J Gruber
, Eric -- You received this message because you are subscribed to the Google Groups Ruby on Rails: Talk group. To post to this group, send email to rubyonrails-t...@googlegroups.com. To unsubscribe from this group, send email to rubyonrails-talk+unsubscr...@googlegroups.com. For more options

[Rails] Re: reCAPTCHA headache

2010-02-07 Thread Eric J Gruber
Hi Sean, thanks for writing. The only error I get is that the words typed were incorrect and that I need to try again. But the words are correct; it's not accepting the words that are typed. Eric On Feb 7, 10:08 pm, Sean Six li...@ruby-forum.com wrote: Is it throwing some kind of rails error

[Rails] Re: reCAPTCHA headache

2010-02-07 Thread Eric J. Gruber
That doesn't look bad, but I'd love to find something that doesn't use RMagick. On Feb 7, 10:26 pm, Sean Six li...@ruby-forum.com wrote: You may want to try this one as an alternative: http://expressica.com/simple_captcha/ -- Posted viahttp://www.ruby-forum.com/. -- You received this

[Rails] Re: Struggling to delete posts... Can you help?

2009-12-05 Thread Eric
Without seeing your view, I'll guess that you're using for foo in @foo do ...if you use @foo.each do |foo| it should work, since .each doesn't return an error on nil like 'for' does. -eric On Dec 5, 9:00 am, RubyonRails_newbie craigwest...@googlemail.com wrote: Cool - thank you

[Rails] Online Auction

2009-12-01 Thread Eric
I'm looking for a script or engine that can be customized. We are building an site that has a specialized auction as part of it's functions. Somethings that will be different from a regular Dutch auction are -multiple bidders will be accepted (grouped to complete the bid) as they will be bidding

[Rails] Re: Heroku.... I'm sceptical

2009-11-25 Thread Eric
, and receive email updates as soon as there's activity on your request. -eric On Nov 25, 12:53 pm, rails.n...@gmail.com rails.n...@gmail.com wrote: About *your* account that *you* pay for. As for proof... well I'm just saying I got my messages filtered out. This group is highly active

[Rails] Re: Creating a new Y object from X's controller

2009-11-21 Thread Eric
Y.new controllers don't care what models you use. -eric On Nov 21, 12:09 pm, RVince rvinc...@hotmail.com wrote: If I am in the controller for Model X, and inside a method there I want to create a new instance of (i.e. insert a new row into the DB table for) Model Y, how do I express

[Rails] Re: security issue: deployment user = :yes or :no?

2009-11-18 Thread Eric
among other reasons, so you can look at the logs and be able to differentiate between connections from deploy and connections from christoph. why aren't you sure you should use a separate account? -eric On Nov 18, 11:48 am, Christoph Jasinski christoph.jasin...@googlemail.com wrote: Hi

[Rails] Re: Propogating the current view's id to a child object

2009-11-17 Thread Eric
]) ... end Once you're back in the view, you can still get the property via the reflexive association in @note via @note.property -eric On Nov 17, 12:30 pm, Todd A. Jacobs tjacobs-sndr- b4f...@codegnome.org wrote: I have a problem with the way I'm currently propagating the object id from

[Rails] Re: Propogating the current view's id to a child object

2009-11-17 Thread Eric
routes.rb: map.resources :properties, :has_many = :notes view: %= link_to 'New note', new_property_note_path(@property) % or however you're holding the property in the view, if not @property... 'rake routes' for more -eric On Nov 17, 2:23 pm, Todd A. Jacobs tjacobs-sndr- b4f

[Rails] Re: Propogating the current view's id to a child object

2009-11-17 Thread Eric
Check your params for the correct property id parameter. -eric On Nov 17, 4:33 pm, Todd A. Jacobs tjacobs-sndr- b4f...@codegnome.org wrote: On Tue, Nov 17, 2009 at 04:16:46PM -0800, Eric wrote: routes.rb: map.resources :properties, :has_many = :notes %= link_to 'New note

[Rails] Re: Authlogic and Restful Authentication - Security Issues

2009-11-15 Thread Eric
is the top Google search result from a query about fixing authlogic session problems with a VPS. -eric On Nov 10, 7:25 pm, Katherine bridgeuto...@gmail.com wrote: Greetings. I need to know an expert's opinion on Authlogic and Restful Authentication as to security. I have used both and I personally

[Rails] Re: How to extend a RESTful route?

2009-11-13 Thread Eric
Well, you could add a 'publish' action to your Document controller and add a 'publish' route. Have you looked at any Rails tutorials yet? -eric On Nov 13, 9:30 am, explainer keburg...@gmail.com wrote: I used the scaffold option to generate a RESTful set of routes to a Document model.  All

[Rails] Re: Getting the last record for an each loop?

2009-11-12 Thread Eric
tasks.each_with_index do |task, index| ... %= content_tag(:hr) unless index == tasks.size % might need a +1 on either of index or .size, but that's the idea. -eric On Nov 12, 5:58 pm, Tony Tony rails-mailing-l...@andreas-s.net wrote: Hi all, I need a very similar functionality to what

[Rails] Re: Trading Google Wave invites for host!

2009-11-11 Thread Eric
Not OK. On Nov 11, 9:16 am, Tim Mcd rails-mailing-l...@andreas-s.net wrote: Trading up to 10 google wave invites for a fast, powerful Rails host that provides me with a top level domain: ie: webwebwebwebweb.com or w.com Or similar offers. Send me an email or post here. -- Posted

[Rails] Re: possible to set flash within link_to?

2009-11-10 Thread Eric
On Nov 10, 5:06 pm, Arif Bandali rails-mailing-l...@andreas-s.net wrote: i want to set the flash in a link_to similar to below: %= (link_to SEND, {:controller = company, :action = show, :id = current_company.id}) % If a flash is set in that code snippet, I sure can't find it.

[Rails] Re: dynamic collection_select

2009-11-09 Thread Eric
Typically for a form, with a submit button. -eric On Nov 9, 10:08 am, Brian Harnett rails-mailing-l...@andreas-s.net wrote: Michal Burak wrote: I think you need AJAX here to populate the cascade rest of the drop downs or refresh the whole page on change of the first drop down and feed

[Rails] Re: is Rails a CMS ?

2009-11-09 Thread Eric
This isn't the appropriate venue for your blogspam. -eric On Nov 9, 12:21 pm, Gaspard Bucher rails-mailing-l...@andreas-s.net wrote: Leonardo Mateo wrote: On Mon, Nov 9, 2009 at 3:38 PM, Gaspard Bucher rails-mailing-l...@andreas-s.net wrote: Hi list ! More often then not when talking

[Rails] Re: Custom Validations Altering Variable

2009-11-07 Thread Eric
I would put this in a callback in the controller. I suggest starting at before_save and go from there. -eric On Nov 7, 8:05 am, 7H3LaughingMan austin.brk...@gmail.com wrote: I would like to know if it is possible to alter a variable during the process of a custom validation. I know

[Rails] Re: Custom Validations Altering Variable

2009-11-07 Thread Eric
I don't agree. Best, Eric On Nov 7, 10:22 am, Marnen Laibow-Koser rails-mailing-l...@andreas- s.net wrote: Eric wrote: I would put this in a callback in the controller. I suggest starting at before_save and go from there. That would work, but I think it's conceptually wrong for what

[Rails] Re: Multiple Model Form

2009-11-07 Thread Eric
mandatory viewing: http://railscasts.com/episodes/73-complex-forms-part-1 you'll probably benefit from watching all of them. -eric On Nov 7, 3:31 pm, eggie5 egg...@gmail.com wrote: I created scaffolding for my Model x, but I want to modify the new view so that I can create multiple (3) x

[Rails] Segmentation Fault in Snow Leopard

2009-11-05 Thread Eric Ee
I just upgraded to snow leopard and I'm trying to get the 64 bit version of mysql and ruby going. I ran through the steps here... http://hivelogic.com/articles/compiling-ruby-rubygems-and-rails-on-snow-leopard/ mysql is running properly and when I run which ruby I get... /usr/local/bin/ruby

[Rails] Re: Segmentation Fault in Snow Leopard

2009-11-05 Thread Eric Ee
Thanks Conrad, However, I also get a segmentation fault when I run sudo gem update --system Conrad Taylor wrote: On Thu, Nov 5, 2009 at 6:07 PM, Eric Ee rails-mailing-l...@andreas-s.netwrote: Which should be right. However, when I go to install rubygems... sudo /usr/local/bin/ruby

[Rails] Re: Segmentation Fault in Snow Leopard

2009-11-05 Thread Eric Ee
Yes, I've got the snow leopard DVD. Went into optional installs and installed Xcode.mpkg before I started any of this. Got a nice checkmark saying it installed properly. still getting segmentation faults with just about everything. Conrad Taylor wrote: On Thu, Nov 5, 2009 at 6:57 PM, Eric

[Rails] Re: Segmentation Fault in Snow Leopard

2009-11-05 Thread Eric Ee
Sure thing. Thank you. Seriously. gem -v Illegal instruction (yikes) which gem /usr/local/bin/gem which ruby /usr/local/bin/ruby Conrad Taylor wrote: On Thu, Nov 5, 2009 at 7:28 PM, Conrad Taylor conra...@gmail.com wrote: Next, what the version of Ruby that you're using? Also,

[Rails] Re: Segmentation Fault in Snow Leopard

2009-11-05 Thread Eric Ee
iPhone On Nov 5, 2009, at 7:38 PM, Eric Ee rails-mailing-l...@andreas-s.net -- Posted via http://www.ruby-forum.com/. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Ruby on Rails: Talk group. To post to this group

[Rails] Re: Segmentation Fault in Snow Leopard

2009-11-05 Thread Eric Ee
Yes! Conrad...you are the man. after a restart and the export path command, I was able to run sudo gem update --system successfully so now... which gem /usr/bin/gem gem -v 1.3.5 which ruby /usr/bin/ruby ruby -v ruby 1.8.7 (2008-08-11 patchlevel 72) [universal-darwin10.0] This has been

[Rails] Re: Ruby QR code decoder?

2009-11-01 Thread Eric
Just that in 10 months of asap you could have implemented any of: http://stackoverflow.com/questions/231741/qr-code-2d-barcode-coding-and-decoding-algorithms Nothing personal, just sayin'. And yeah, there seem to be any number of system call solutions. -eric On Nov 1, 12:09 pm, ckundo cku

[Rails] Re: *** PLEASE HELP!! *** NoMethodError in AvatarController#upload

2009-10-31 Thread Eric
Fred's right. If hub_url is news to you, it's probably either a bug in the book or a skipped section by you. -eric On Oct 31, 6:59 am, RubyonRails_newbie craigwest...@googlemail.com wrote: There's nothing in the routes.rb file for this section, so am assuming it hasnt been affected

[Rails] Re: *** PLEASE HELP!! *** NoMethodError in AvatarController#upload

2009-10-31 Thread Eric
causing an issue at the moment, it's this: NoMethodError in AvatarController#upload You have a nil object when you didn't expect it! You might have expected an instance of ActiveRecord::Base. The error occurred while evaluating nil.delete On 31 Oct, 17:04, Eric ericgh...@gmail.com wrote

[Rails] Re: Ruby QR code decoder?

2009-10-31 Thread Eric
i don't mean to be a jerk, but asap? really? http://www.ruby-forum.com/topic/198410 -eric On Oct 31, 3:17 pm, ckundo cku...@gmail.com wrote: I'd like to use be able to decode QR codes that people submit to my rails app. I'm using phonegap for iPhone, so I need to create a work- around

[Rails] Re: What is the future of Ruby on Rails? MySQL? Compare with Java, MS SQL or Oracle?

2009-10-29 Thread Eric
On Oct 28, 1:51 pm, Suki sukio...@gmail.com wrote: Just got into this ROR world, and wondering  around! Would like to hear what others think about  ROR. Personally? I like it. -eric --~--~-~--~~~---~--~~ You received this message because you are subscribed

[Rails] Re: activerecord has_many vs. has_one scope

2009-10-27 Thread Eric
to handle this situation, but my instinct is to use named scopes for the color finds and validations to enforce the one-of-each. Another way would be to use STI to set up color models that inherit from Thing, with the has_ones from ThingContainer pointing to each. -eric On Oct 27, 1:47 pm, Chris

[Rails] Re: Rails generator fails to generate all files

2009-10-21 Thread Eric
`rails myproject -d mysql -t` will get you a backtrace. -eric On Oct 21, 9:30 am, Arthur Rats rails-mailing-l...@andreas-s.net wrote: Hi Marnen Yes did look into the locations - its Ruby 1.9 playing up, uninstalled/re installed Rails gem didnt make any difference went back to 1.8.7

[Rails] Re: %= %, %- % and % -%

2009-10-21 Thread Eric
the hyphens suppress newlines. i'm not sure if the single versions are equal, but i double them up just out of habit: %- ... -% -eric On Oct 21, 12:21 pm, Duke Yamamoto rails-mailing-l...@andreas-s.net wrote: When I want to show output, %= % When I do not want to show output

[Rails] Re: Deploying rails application

2009-10-19 Thread Eric
script/server -h -eric On Oct 18, 6:19 pm, Josh6847 josh.rach...@gmail.com wrote: I am looking to set my rails application into production mode. Does anyone have easy instructions on this or good documentation? Thanks in advance. Josh

[Rails] Re: Project Server not starting. No Errors.

2009-10-18 Thread Eric
versions? check script\about On Oct 18, 5:27 pm, Peter Warrick rails-mailing-l...@andreas-s.net wrote: I apologize if this has been asked before. I'm trying to simply start my server and the only output is as follows... ruby script/server ./script/../config/boot.rb:26:Warning:

[Rails] Re: Project Server not starting. No Errors.

2009-10-18 Thread Eric
The app was written for an older version of rails, do you have those versions installed? -eric On Oct 18, 8:21 pm, Peter Warrick rails-mailing-l...@andreas-s.net wrote: Eric wrote: versions? check script\about On Oct 18, 5:27 pm, Peter Warrick rails-mailing-l...@andreas-s.net Eric

[Rails] Re: how do I tell people about my open source Rails project?

2009-10-16 Thread Eric
here's one: http://www.google.com/addurl/ On Oct 16, 12:12 pm, Jason jason.lillywh...@gmail.com wrote: I have a site built in RoR that I would to tell people about. Is there some list of RoR projects that people look at? How do I submit my site to that list? It iswww.hyop.org. Thanks.

[Rails] Re: Am I reinventing polymorphic associations?

2009-10-15 Thread Eric
I think you are. I'd make Comment polymorphic, a nested set, and has_many :subscribers, which should be based on the top parent of the comment thread. -eric On Oct 15, 4:32 pm, Scott Johnson sc...@scottjohnson.org wrote: Am I reinventing polymorphic associations? I have a fairly standard

[Rails] Re: Really need some help with production environment installation

2009-10-14 Thread Eric
J, Can you paste in exactly what is in your PATH now? That might help clear up where the problem is. And yes, if you are following the Hivelogic instructions for the Ruby/Rails/Gem install you will need something in your PATH. On Oct 14, 8:49 am, Jez jezcow...@gmail.com wrote: Hello again,

[Rails] doing creates on has_many_through associations with :conditions?

2009-10-05 Thread Eric Hahn
| | ++-+-+---+ Which seems plain wrong. I'd think the moderator column should be 't' for the second user's membership since he was added via the :moderators association which has a conditions clause. What am I misunderstanding? Thanks much. -Eric ps: Rails 2.3.4 pps: no apparent difference if I rewrite

[Rails] Re: newcomer of ROR

2009-10-05 Thread Eric
On Oct 5, 12:36 pm, silver liuchen7...@gmail.com wrote: But I have trouble with how to do it. I want to call the category's list action from blog/list.rhtml but I don't know how to do it. What have you tried so far? -eric --~--~-~--~~~---~--~~ You received

[Rails] Re: Knowing the parent of an object

2009-10-03 Thread Eric
I totally agree, but it would be convenient to obtain an array of multiple parents.  Something like: parents = @article.belongs_to parents # = [Magazine, Category] Look into reflections, there should be something in there you can rely on. -eric

[Rails] What is the Ruby on Rails equivalent to php includes?

2009-09-30 Thread Eric J. Gruber
If I was to include a file (such as in a template) in php to use across a large number of pages, I would write this: ?php include ('navigation.html'); ? In turn, every time I used this code, it would “include” (or better put, display) the content of navigation.html in the browser. I can’t

[Rails] Re: What is the Ruby on Rails equivalent to php includes?

2009-09-30 Thread Eric Gruber
, Greg Donald gdon...@gmail.com wrote: On Wed, Sep 30, 2009 at 10:44 AM, Eric J. Gruber e...@rumblestrut.com wrote: If I was to include a file (such as in a template) in php to use across a large number of pages, I would write this: ?php include ('navigation.html'); ? In turn, every time

[Rails] Re: What is the Ruby on Rails equivalent to php includes?

2009-09-30 Thread Eric Gruber
OK ... so is there another way to do it without using render? Surely this isn't something that PHP can do that Rails can't. On Sep 30, 11:04 am, Eric Gruber e...@rumblestrut.com wrote: Right. That helps if the file I am using is locally. But what do I do if that file is from another server

[Rails] Re: What is the Ruby on Rails equivalent to php includes?

2009-09-30 Thread Eric Gruber
If there's some sort of risk, please inform. Not that it matters, that didn't work either. On Sep 30, 11:13 am, John Barnette jbarne...@gmail.com wrote: On Sep 30, 2009, at 9:06 AM, Eric Gruber wrote: OK ... so is there another way to do it without using render? Surely this isn't

[Rails] Re: What is the Ruby on Rails equivalent to php includes?

2009-09-30 Thread Eric Gruber
I should clarify. 1. I control both servers that I'm working with, so the security risk is practically nil. 2. The app is very small. Any performance hits I'd take by including a remote file is acceptable. That said, still don't have a fix. Thanx. Eric On Sep 30, 11:17 am, Eric Gruber e

[Rails] Re: What is the Ruby on Rails equivalent to php includes?

2009-09-30 Thread Eric Gruber
server, so if I have to make a change to that one file (remember kids, don't repeat yourself!) I have to only do it once on one server. On Sep 30, 11:56 am, Marnen Laibow-Koser rails-mailing-l...@andreas- s.net wrote: Eric Gruber wrote: If there's some sort of risk, please inform. I agree

[Rails] Re: What is the Ruby on Rails equivalent to php includes?

2009-09-30 Thread Eric Gruber
server, so if I have to make a change to that one file (remember kids, don't repeat yourself!) I have to only do it once on one server. On Sep 30, 11:56 am, Marnen Laibow-Koser rails-mailing-l...@andreas- s.net wrote: Eric Gruber wrote: If there's some sort of risk, please inform. I agree

[Rails] Re: What is the Ruby on Rails equivalent to php includes?

2009-09-30 Thread Eric Gruber
\n/HTML\r \n\r\n On Sep 30, 2:07 pm, Eric Gruber e...@rumblestrut.com wrote: What happened was I got the We're sorry, but something went wrong. page from my app. I would prefer it all to be on one server, but the company I'm trying to do this for has many different projects, using

[Rails] Re: App isn't querying db on server, but works in development

2009-09-30 Thread Eric Gruber
to troubleshoot. Eric On Sep 21, 8:42 pm, Eric Gruber e...@rumblestrut.com wrote: Sorry for the delay, I've been out of town. Here's the query from the terminal on my development machine, with a known good term (fire): Processing PostsController#get_results (for 127.0.0.1 at 2009-09-21 20:36:34

[Rails] Re: arrays into columns

2009-09-28 Thread Eric
No, not valid; you want an association. Read here: http://www.google.com/#hl=enq=rails+database+cardinality On Sep 27, 4:20 pm, sajeev86 sajee...@mac.com wrote: hey (first post jitters..) Im a baby in rails web development-please be obvious How would I get an array as a column set of data?

[Rails] Re: App best practice Client Credit Information

2009-09-27 Thread Eric
Did I read you correctly in that you want to store user credit-card numbers in your database for some period of time? -eric On Sep 27, 3:50 pm, brianp brian.o.pea...@gmail.com wrote: Hey Everyone, I'm in the process of laying out a new app for a client. They need to be able to receive

[Rails] Re: Search Pluging , Acts_as_ferret with conditions

2009-09-24 Thread Eric
http://www.google.com/#hl=ensource=hpq=find_with_ferret+conditions looks like you might need a nil in the middle, there. check the api. -eric On Sep 23, 11:23 pm, Neetal Sharma rails-mailing-l...@andreas-s.net wrote: I have a search feature in my application. I was using acts_as_ferret , i

[Rails] Re: Editing Tutorials

2009-09-24 Thread Eric
What do you mean your tutorials are stored inside categories? Also: rake routes -eric On Sep 24, 11:09 am, Joe j...@dev-hq.co.uk wrote: Hi, Ive recently bene trying to find a way to edit my tutorials (which are stored inside categories) in my RoR app. To edit my category's names I use

[Rails] Re: App isn't querying db on server, but works in development

2009-09-21 Thread Eric Gruber
/_search (0.6ms) Completed in 19ms (View: 3, DB: 1) | 200 OK [http://localhost/posts/ get_results] Thanx, Eric On Sep 14, 11:42 pm, Hassan Schroeder hassan.schroe...@gmail.com wrote: On Mon, Sep 14, 2009 at 9:32 AM, Eric Gruber e...@rumblestrut.com wrote: Here's my code for the suspected

[Rails] Re: render :partial = @object

2009-09-20 Thread Eric
Is there something I'm not getting here? The short form should be either render :partial = @foo -or- render @foo I've never seen render :partial @foo -eric On Sep 19, 9:44 pm, Me chabg...@gmail.com wrote: Running rails  2.1.0 when I do this: %= render :partial = 'style', :collection

[Rails] Re: How to: redirect_to through a folder hierarchy (upwards)

2009-09-19 Thread Eric
-eric On Sep 19, 8:20 am, Tom Ha rails-mailing-l...@andreas-s.net wrote: Hi there, how do I tell the current controller correctly to redirect_to an action of another controller that is 1 level higher in the folder hierarchy than the current controller? How I have tried: Within the current

[Rails] Re: Ensuring a password is Alpha-Numeric

2009-09-19 Thread Eric
I'd think the easiest way to allow people to use whatever characters they want would be not to use validates_format_of at all. -eric On Sep 19, 7:06 am, Marnen Laibow-Koser rails-mailing-l...@andreas- s.net wrote: RubyonRails_newbie wrote: Hi there, I am trying to make every effort

[Rails] Re: Polymorphic STI with associations

2009-09-17 Thread Eric
On Sep 17, 8:44 am, Matt Jones al2o...@gmail.com wrote: On Sep 16, 1:52 pm, Eric ericgh...@gmail.com wrote: I have been working on a polymorphic STI schema where the inheriting classes have associations: class Asset ActiveRecord::Base end class Sound Asset   belongs_to :user

[Rails] Re: Polymorphic STI with associations

2009-09-17 Thread Eric
On Sep 17, 11:10 am, Eric ericgh...@gmail.com wrote: On Sep 17, 8:44 am, Matt Jones al2o...@gmail.com wrote: On Sep 16, 1:52 pm, Eric ericgh...@gmail.com wrote: I have been working on a polymorphic STI schema where the inheriting classes have associations: class Asset

[Rails] Polymorphic STI with associations

2009-09-16 Thread Eric
a :destroy for the object). However, now that I've added it, the user_type is not being populated when new objects are created/saved. Am I missing something? -eric --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Ruby

[Rails] Re: App isn't querying db on server, but works in development

2009-09-14 Thread Eric Gruber
Very interesting. I had no idea SQL queries didn't show up in the production log. Here's my code for the suspected offending method. Is there something in that query that wouldn't work with MySQL but OK with SQLite3? def get_results if request.xhr? if

[Rails] Re: Proper syntax for text_field

2009-09-13 Thread Eric
Text fields don't take actions, they're just text fields with some optional aesthetics. put :amount in there, and if item.amount exists, it will be filled in. http://api.rubyonrails.org/classes/ActionView/Helpers/FormHelper.html#M001607 Also, ruby doesn't use This, it's self. There may be

[Rails] Re: App isn't querying db on server, but works in development

2009-09-12 Thread Eric Gruber
Any ideas? On Sep 11, 1:25 pm, Eric J. Gruber e...@rumblestrut.com wrote: I've got a very small app that uses ajax for a live preview. On my development machine (using sqlite3), it works just fine. Here is a sample of the log with a known good query: development.log

[Rails] Re: Counter cache help

2009-09-11 Thread Eric
Singularize your model names: Comment TestCase -e On Sep 10, 8:50 pm, James Englert englert.ja...@gmail.com wrote: My :counter_cache column isn't working properly. I wouldn't normally ask about a relatively trivial issue like this but I've been banging my head on this for a bit and haven't

[Rails] Re: Potential fix to broken session_options in Rails 2.3

2009-09-10 Thread Yves-eric Martin
open... Can anyone help? Should I fill a bug report? -- Yves-Eric Martin -- Posted via http://www.ruby-forum.com/. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Ruby on Rails: Talk group. To post to this group

[Rails] Re: Nesting View Folders

2009-09-10 Thread Eric
It's an aesthetic decision, so...y'know, do what you want, but it's not necessary since you're introducing complexity in having to maintain a bunch of of prepend_view_path lines everywhere. http://en.wikipedia.org/wiki/Convention_over_configuration On Sep 10, 9:22 pm, Mark Dodwell

[Rails] Potential fix to broken session_options in Rails 2.3

2009-09-09 Thread Yves-eric Martin
Hi all, Reviving this old thread with a I am developing a site that needs to be accessible to mobile phones, and I am having issues with session tracking. While the default cookie_only session tracking makes a lot of sense (it prevents session fixation attacks), there are these cases when

[Rails] Re: partials in layouts ?

2009-09-08 Thread Eric
works. Seems kind of ugly, though--even in layouts, shouldn't a form look in its own directory for a partial? It does, you're just misunderstanding what its own directory refers to. Your form is not a part of layouts, it's a part of the controller rendering it. On Sep 8, 6:30 am, Dudebot

[Rails] Re: Controller Actions

2009-09-07 Thread Eric
egrep -r '^ *?def ' /path/to/proj/app/controllers/ methods_and_actions.csv On Sep 7, 10:22 pm, Avantec Van rails-mailing-l...@andreas-s.net wrote: Hi All,   How do I get all the actions methods from a no. of controllers export it into excel. Thanks in Advance, Avantec -- Posted

[Rails] Re: Format of a string, array or hash

2009-09-06 Thread Eric
@project.services.collect{|s| s.name}.to_sentence On Sep 6, 3:33 pm, Hugues Brunelle rails-mailing-l...@andreas-s.net wrote: Hello there, I do not know if my topic is right so I'll explain the problem : I have a Project model : class Project ActiveRecord::Base   has_and_belongs_to_many

[Rails] Passenger problem

2009-09-01 Thread Eric J Gruber
I've used the Slicehost Intrepid instructions (http:// articles.slicehost.com/ubuntu-intrepid) to install a new Ubuntu server with Ruby, Rails and passenger. Everything seems to be working OK, save for one thing: my application only service up the files that are in its public folder. The

[Rails] Re: Passenger problem

2009-09-01 Thread Eric J Gruber
Any troubleshooting 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

[Rails] Re: render :partial erroring with wrong extension

2009-08-28 Thread Eric
Of course it was the one thing I didn't check and was not in the error: a leading space in the partial's filename. A twitchy typo, and a proportional font didn't help either. On Aug 27, 12:46 pm, Eric ericgh...@gmail.com wrote: I'm thinking that for some reason Rails isn't seeing a content_type

[Rails] render :partial erroring with wrong extension

2009-08-27 Thread Eric
I'm thinking that for some reason Rails isn't seeing a content_type so is falling back to .erb rather than using .html.erb, but I can't figure out how this would happen or why it's not able to find the correct file. I encountered this when changing this view from %= render @gigs %, which finds

[Rails] Re: Grab only the latest comment

2009-08-26 Thread Eric
http://api.rubyonrails.org/classes/ActiveRecord/Base.html On Aug 26, 6:25 pm, gkrdvl gkr...@gmail.com wrote: Hi all In a typical User - Post - Comment model in Rails, every user can create a Post and also can create Comment, question is how to grab every user latest comment on specific

[Rails] Re: Authlogic Forgot Password

2009-08-24 Thread Eric
Apropos to this, it's good to at least attempt to plug your subject line into Google. On Aug 24, 2:36 am, Abhishek shukla bettera...@gmail.com wrote: http://www.binarylogic.com/2008/11/16/tutorial-reset-passwords-with-a... this might help u regards abhis On Mon, Aug 24, 2009 at 9:14 AM,

[Rails] Re: FULL TIME RoR POSITION- SEATTLE, WA

2009-08-24 Thread Eric
Though you don't list it as a starred requirement, the wording suggests that you may want to refer to the following document before composing future job reqs: http://www.eeoc.gov/policy/docs/religion.html On Aug 24, 10:56 am, Jake jaker...@gmail.com wrote: We are seeking a Ruby on Rails

[Rails] Re: What to do before launching v1.0?

2009-08-22 Thread Eric
rsync is a good place to start. On Aug 22, 2:01 pm, bingo bob rails-mailing-l...@andreas-s.net wrote: always seems to come back to testing (which I keep trying and failing to grasp). Thanks though - noted. I pretty much got backups sorted today with this rake task, ideal

[Rails] Re: Building a social Networking site...

2009-08-22 Thread Eric
a social-network- specific tutorial. Social networks are basically just accounts, friends and messages, filling out features as you like, no? These all involve basic programming concepts that you should learn anyway, and there's plenty of information on the internet about each element. -eric

[Rails] Re: Starter DB's (general web app question) Where to get them?

2009-08-20 Thread Eric
it will be, and beyond some level of detail you are getting into proprietary models which typically require money, licensing, equity, or all three. -eric -eric --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Ruby on Rails: Talk group

[Rails] Re: why partial doesn't work ?

2009-08-09 Thread Eric
/_preview.html.erb file, create a 'preview' variable for each element of the @previews object, which can then be used with same preview.body, etc. syntax in the _preview partial as outlined above. TIMTOWTDI, natch, but I think this all is pretty close to what you're asking about. -eric

[Rails] Re: CDN for Rails - any recommendations?

2009-08-09 Thread Eric
They should all be pretty much the same, requiring only certain URL prefixes for your content. You may have to randomize hostnames if you go with one that allocates blocks of nodes, but that's about it. -eric On Aug 9, 3:10 pm, Alpha Blue rails-mailing-l...@andreas-s.net wrote: Are there any

[Rails] Re: using a link conditionally in the view

2009-08-05 Thread Eric
one way: link_to(obj.status_name, #{obj.status}_path) this would require any extra routes to be added, as well as a status_name attribute/model to supply the text. On Aug 5, 2:31 pm, Brad brad.we...@gmail.com wrote: I want to render a different link_to name and url path based on an objects

<    1   2   3   4   >