[Rails] Re: Carrierwave Direct and additional form elements

2012-08-30 Thread tundrax
Docs say you should use Fog gem https://github.com/jnicklas/carrierwave#using-amazon-s3 And it doesn't matter what storage you chose, local filesystem, S3 or any other cloud storage. Your form is submitted and the location of uploaded file, along with other attributes of the model you are editi

[Rails] Re: custom js in rails project

2012-08-30 Thread tundrax
Try including js in order like you had before. # in your application.js //= require jquery //= require jquery_ujs //= require 'foundation.min' //= require 'app' //= require 'jquery.foundation.navigation' //= require 'modernizr.foundation' //= require 'mijs' On Thursday, August 30, 2012 4:54:01

[Rails] Re: rvm and gem confusion

2010-11-29 Thread tundrax
Maybe your RVM is not running as a function that is causing gem env confusion. Check out the manual, Post Install section. Run "type rvm | head -n1" and check if the return is "rvm is a function". And if it's not, follow the instructions given in the manual. Hope this helps. On Nov 30, 9:11 am, M

[Rails] Re: Dynamic find_by method returning nil in a class method

2010-11-29 Thread tundrax
Try using user = self.find_by_email(email) On Nov 29, 7:27 am, Matthew Wallace wrote: > I have a user Model with a class method that I am using to do some > authentication > > basically something like this > > class User < ActiveRecord::Base > >   attr_accessor   :password >   attr_accessible :fi

[Rails] Re: Dynamic find_by method returning nil in a class method

2010-11-29 Thread tundrax
Try this one user = self.find_by_email(email) On Nov 29, 7:27 am, Matthew Wallace wrote: > I have a user Model with a class method that I am using to do some > authentication > > basically something like this > > class User < ActiveRecord::Base > >   attr_accessor   :password >   attr_accessibl

[Rails] Re: Facebook like page Count

2010-11-29 Thread tundrax
"a Facebook like page Count" what do you mean? On Nov 29, 2:42 pm, ashu wrote: > How can i count a Facebook like page Count in my rails application and > need to save that in my db. > > or need to know :fb_like => 'true' Or false -- You received this message because you are subscribed to the Go

[Rails] Re: has_one accepts_nested_attributes_for fields_for NOT WORKING HELP

2010-11-29 Thread tundrax
Section 7.4.2 of http://guides.rubyonrails.org/3_0_release_notes.html On Nov 29, 2:08 pm, Humberto Ribeiro wrote: > The result is the same... the field do not show in view when browsing > to /users/new > > On 28 nov, 14:51, ssmithstone wrote: > > > > > > > > > in your > > > def new > > > try @us

[Rails] Re: has_one accepts_nested_attributes_for fields_for NOT WORKING HELP

2010-11-28 Thread tundrax
Just tested. Everything works fine. Make sure: 1) you didn't forget to put "belongs_to :user" association in your Address model 2) use "<%=" for your "f.fields_for :address" in the _form view file. Hope this helps. On Nov 29, 2:08 pm, Humberto Ribeiro wrote: > The result is the same... the fie

[Rails] Encoding::UndefinedConversionError on a simple file upload (rvm, MRI-1.9.2-p0, rails 3.0.1, apache+passenger)

2010-10-31 Thread tundrax
Hello everyone. I am having the encoding issue on a simple file upload action: Encoding::UndefinedConversionError in MainController#upload "\xC4" from ASCII-8BIT to UTF-8 The action looks like this: def upload @uploaded_io = params[:upload] File.open(Rails.root.join('public', 'images',

[Rails] Re: partials issue

2010-09-22 Thread tundrax
Try using <%= render 'form', :seat => @seat %> without locals. On Sep 22, 3:50 pm, Veera Sundaravel wrote: > pass the seat variable with your render call something like this, > > <%= render 'form', :locals => { :seat => @seat } %> > > -- > Regards, > > T.Veerasundaravel.http://tinyurl.com/25vma7h

[Rails] Re: Devise - alert messages not showing up

2010-09-21 Thread tundrax
to the documentations (README) the last paragraph in "Configuring controllers" section. On Sep 22, 12:33 pm, Rick R wrote: > On Tue, Sep 21, 2010 at 11:17 PM, tundrax wrote: > > @Rick: What do you mean by "if I try to sign in (using Devise)" and > > "If I'm

[Rails] Re: Devise - alert messages not showing up

2010-09-21 Thread tundrax
@Rick: What do you mean by "if I try to sign in (using Devise)" and "If I'm on the login screen however"? Are trying to sign in a Model from another controller and you redirect back if login was not successful? Everything works fine for me. One more thing, make sure you set the flash messages expl