[Rails] Re: Upload file with url parameter

2009-05-12 Thread Starr Horne
The only way to do anything like that would be to have the user install a client on their computer. For example, you can upload arbitrary files using adobe air. But otherwise, is verboten. SH -- Starr Horne Check out my Helpdesk RailsKit: http://railskits.com/helpdesk

[Rails] Re: Integration testing edit actions (PUT method)

2009-05-12 Thread Starr Horne
in your integration test doesn't get routed to the correct action, the test will fail anyway. SH -- Starr Horne Check out my Helpdesk RailsKit: http://railskits.com/helpdesk/ --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google

[Rails] Re: [ROUTES] [RAILS 2.3] Custom controller method fires a route error...

2009-05-06 Thread Starr Horne
? map.connect '/import/generate/', :controller = 'import', :action = 'generate' -- Starr Horne Check out my Helpdesk RailsKit: http://railskits.com/helpdesk/ --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Ruby on Rails: Talk

[Rails] Re: [ROUTES] [RAILS 2.3] Custom controller method fires a route error...

2009-05-06 Thread Starr Horne
sparingly. -- Starr Horne Check out my Helpdesk RailsKit: http://railskits.com/helpdesk/ --~--~-~--~~~---~--~~ 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

[Rails] Re: Rails 2.3.2 Ajax posting to XML

2009-04-06 Thread Starr Horne
basically the pervious person was doing an ajax call using path/to5.xml?_method=delete and then posting, however with 2.3.2, this is no longer allowed? You might try posting the _method parameter instead of including it in the querystring. SH -- Starr Horne Check out my Helpdesk RailsKit

[Rails] Re: site with drupal vs ruby

2009-04-01 Thread Starr Horne
not a lot of money for this kind of project, no matter what framework/cms is used. Especially when you start talking about integration with other systems, etc. That sort of thing can take a lot of time, unless you get lucky and can find a 3rd party solution. -- Starr Horne Check out my Helpdesk

[Rails] Re: form_for, partials, and link_to_remote

2009-03-31 Thread Starr Horne
? Nope. But you can always just use the older text_field_tag type methods in your partial. SH. -- Starr Horne Check out my Helpdesk RailsKit: http://railskits.com/helpdesk/ --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google

[Rails] Re: help with code

2009-03-26 Thread Starr Horne
for rails?? Post parameters are available in the view via the params method. Are you seriously trying to put PHP code in your views? Or do you want to port the php to ruby? SH -- Starr Horne Check out my Helpdesk RailsKit: http://railskits.com/helpdesk

[Rails] Re: How to pass javascript variable value to a Session Variable in javascript

2009-03-19 Thread Starr Horne
sessions mechanism. 2) Have your JS do an XHR request to a special controller action which will save your data to the session. -- Starr Horne Check out my Helpdesk RailsKit: http://railskits.com/helpdesk/ --~--~-~--~~~---~--~~ You received this message because

[Rails] Re: Extracting just the text of an ActionMailer receive e-mail

2009-03-19 Thread Starr Horne
, recommendations or links I should be following? Take a look at MMS2R. While it was written to handle MMS message, it's good at pulling apart any kind of email. -- Starr Horne Check out my Helpdesk RailsKit: http://railskits.com/helpdesk

[Rails] Re: ActiveRecord shared models

2009-03-19 Thread Starr Horne
. Have you tried the new plugin system in rails 2.3? It may not be exactly what you're looking for, but it allows you to have models in plugins. SH -- Starr Horne Check out my Helpdesk RailsKit: http://railskits.com/helpdesk/ --~--~-~--~~~---~--~~ You received

[Rails] Re: Problem with restful_authentication

2009-03-18 Thread Starr Horne
/views/controller. So you can edit those to accept your extra fields. SH -- Starr Horne Check out my Helpdesk RailsKit: http://railskits.com/helpdesk/ --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Ruby on Rails: Talk

[Rails] Re: Problem with restful_authentication

2009-03-18 Thread Starr Horne
the extra fields to the model? Have you tried opening a console and manually creating a user model? That would tell you if the problem's in your model or in your controller/view SH -- Starr Horne Check out my Helpdesk RailsKit: http://railskits.com/helpdesk

[Rails] Re: Problem with restful_authentication

2009-03-18 Thread Starr Horne
On Wed, 18 Mar 2009 15:51:34 +0100 Indu RS rails-mailing-l...@andreas-s.net wrote: Yes , I am sure, that I am passing the extra fields to the model. Hmm, well it should work then :) It might be useful for you to post some code. SH -- Starr Horne Check out my Helpdesk RailsKit: http

[Rails] Re: New Browser Window using AJAX

2009-03-13 Thread Starr Horne
will be blocked if it's called by a timer, or some other non-user source. SH -- Starr Horne My blog: http://starrhorne.com Check out my Helpdesk RailsKit: http://railskits.com/helpdesk/ --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google

[Rails] Re: not logged in in subdomain?

2009-03-12 Thread Starr Horne
://szeryf.wordpress.com/2008/01/21/cookie-handling-in-multi-domain-applications-in-ruby-on-rails/# SH -- Starr Horne My blog: http://starrhorne.com Check out my Helpdesk RailsKit: http://railskits.com/helpdesk/ --~--~-~--~~~---~--~~ You received this message because

[Rails] Re: Does anybody have simple example of Tiny_MCE working?

2009-03-12 Thread Starr Horne
the tinymce rails plugin. You just drop it in to your app, and it works like a charm. Unfortunately, I don't have any code I can post, though. SH -- Starr Horne My blog: http://starrhorne.com Check out my Helpdesk RailsKit: http://railskits.com/helpdesk

[Rails] Re: Return only some resources from 2 tables

2009-03-11 Thread Starr Horne
category @character_attribute_types += CharacterAttributeType.find_all_by_character_attribute_category_id cat.id } Do you mean this? @character_attribute_types = [] @character_attribute_types CharacterAttributeType.find_all_by_character_attribute_category_id SH -- Starr Horne My blog: http

[Rails] Re: Annoying pop up window with restful_authentication

2009-03-10 Thread Starr Horne
require a little work. SH -- Starr Horne My blog: http://starrhorne.com Check out my Helpdesk RailsKit: http://railskits.com/helpdesk/ --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Ruby on Rails: Talk group. To post

[Rails] Re: Implementing a dashboard-style controller, (think iGoogle)

2009-03-10 Thread Starr Horne
elegant enough to be standard practice. I would probably just create partials for each type of module. Then you can use render :partial = @module, which will render the correct partial for the object type. SH -- Starr Horne My blog: http://starrhorne.com Check out my Helpdesk RailsKit: http

[Rails] Re: inheritance problem

2009-03-10 Thread Starr Horne
i create java class and i want to create ruby class and inherit from this java class You just need to write an adapter in c# and you should be all set. SH --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Ruby on

[Rails] Re: Managing migrations

2009-03-10 Thread Starr Horne
What the best way to handle something like this? Is it insane to just manually delete a migration file to prevent it from ever being ran again? Yeah, you can delete it. It's just a file. -- Starr Horne My blog: http://starrhorne.com Check out my Helpdesk RailsKit: http://railskits.com

[Rails] Re: Managing migrations

2009-03-10 Thread Starr Horne
the extra migration. If you're early in development, I'd just delete it to keep things clean. SH -- Starr Horne My blog: http://starrhorne.com Check out my Helpdesk RailsKit: http://railskits.com/helpdesk/ --~--~-~--~~~---~--~~ You received this message because you

[Rails] Re: how to give default value to fields in a model while creating model_name.new()

2009-03-05 Thread Starr Horne
Are you using mysql? If so, it doesn't support default values for text columns. SH -- Starr Horne My blog: http://starrhorne.com Check out my Helpdesk RailsKit: http://railskits.com/helpdesk/ --~--~-~--~~~---~--~~ You received this message because you are subscribed

[Rails] Re: rails w/ jquery

2009-03-04 Thread Starr Horne
it in and it changes the built in JS jelpers to use jquery. http://ennerchi.com/projects/jrails -- Starr Horne My blog: http://starrhorne.com Check out my Helpdesk RailsKit: http://railskits.com/helpdesk/ --~--~-~--~~~---~--~~ You received this message because you

[Rails] Re: link_to/url_for in an model object quandry

2009-03-04 Thread Starr Horne
of your player data in the model 2) Use an actionmailer template for the email 3) Use normal views for the pages SH -- Starr Horne My blog: http://starrhorne.com Check out my Helpdesk RailsKit: http://railskits.com/helpdesk/ --~--~-~--~~~---~--~~ You received

[Rails] Re: rails w/ jquery

2009-03-04 Thread Starr Horne
On Wed, 4 Mar 2009 08:08:45 -0600 Greg Donald gdon...@gmail.com wrote: When I tried it, about 4 or 5 months ago, it did work, but it didn't play nice with prototype. Perhaps it's improved since. Ahh. Well I never it with prototype, so I couldn't say. SH -- Starr Horne My blog: http

[Rails] Re: link_to/url_for in an model object quandry

2009-03-04 Thread Starr Horne
in your rake task, either. Here's instructions on how to include them: http://stuartsierra.com/2008/01/08/testing-named-routes-in-the-rails-console -- Starr Horne My blog: http://starrhorne.com Check out my Helpdesk RailsKit: http://railskits.com/helpdesk

[Rails] Re: Catch the browser close event

2009-03-03 Thread Starr Horne
window.onbeforeunload = bunload; function bunload() The beforeunload event is also fired on page refresh when you browse away from the current page. Also, what happens if the power goes out on the user's computer? Really, there's no way to detect a real browser close event in a way that

[Rails] Re: RoR for dummies .. from nothing to knowlege

2009-03-03 Thread Starr Horne
/0321480791/ref=pd_bbs_sr_1?ie=UTF8s=booksqid=1236105978sr=8-1 -- Starr Horne My blog: http://starrhorne.com Check out my Helpdesk RailsKit: http://railskits.com/helpdesk/ --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups

[Rails] Re: RESTful app and refactoring code in different controllers

2009-03-03 Thread Starr Horne
yoursite.com/topics/sometopic Then in the view you just loop through @topic.articles, etc. Just because you have a restful URL scheme, it doesn't mean that your view can only display data from one model. SH -- Starr Horne My blog: http://starrhorne.com Check out my Helpdesk RailsKit: http

[Rails] Re: Catch the browser close event

2009-03-02 Thread Starr Horne
I'm pretty new in rails so I've been playing programming simple app one of the was an app with a login and session management. Up to here, everything is pretty smooth, as rails; but I have a question that I can solve, that's why I'm writing to the group. Is there a way to catch the

[Rails] Re: Model Knowledge Of Controller Calling It

2009-03-02 Thread Starr Horne
Does anyone know a good way for a Model to be aware of which Controller is calling it? For example, I have an after_find method that should always be called unless the Controller is the 'FooController'. This doesn't sound like such a good idea. Isn't the whole point of the MVC architecture

[Rails] Re: rest-ish method for subsetting an index view?

2009-02-28 Thread Starr Horne
You could always do something like this: map.connect '/people/:role', :controller = 'people', :action = 'index' Personally, I'd probably go with a url structure like /people/filter/programmers: map.resources :people, :collection = { :filter = :get } SH

[Rails] Re: what / when calls create function in an ActionController ?

2009-02-27 Thread Starr Horne
even deleting the create function , it shows no error but returns to index page when submit button clicked . it seems that this function is not called properly Have you set up your routes.rb file? SH --~--~-~--~~~---~--~~ You received this message because you

[Rails] Re: rails array.each returning array?

2009-02-27 Thread Starr Horne
does anyone know where the = [a, b, c] is coming from? It's only doing that in the console, because the return value of each is the array you passed it. If you run this code outside of irb, you won't see it. SH --~--~-~--~~~---~--~~ You received this message

[Rails] Re: Is a global set of named_scope scopes a bad idea? If not, is it possible?

2009-02-27 Thread Starr Horne
When you tried using a module, did you try it like this? ie. putting the calls to named_scope inside self.included ? module MyScopes def self.included(base) base.send :named_scope, ... params ... Another option might be to make a plugin with your named scopes in them. SH