Sign in through GitHub

Please read for an updated status on RailsCasts:

Learn more or hide this

cbmeeks's Profile

GitHub User: cbmeeks

Site: http://flocktravel.com

Comments by cbmeeks

Avatar

Did you spend the same two weeks learning AngularJS? Makes sense that if you spend two weeks on something then it will start to make perfect sense. It's just because you are learning it. ;-)

Avatar

Awesome! I have all of the full screen JS calendars I've seen. This is nice and clean and can easily be customized.

Great job.

Avatar

I found the answer to this. It's in the:

user.oauth_expires_at = Time.at(auth.credentials.expires_at)

For my account, auth.credentials.expires_at does not exist. So Time.at was converting nil. For my account, I only had:

auth.credentials.token
auth.credentials.expires

So put some validation checking in there for that line and you should be good to go.

Avatar

UGH!!! I clean installed Mountain Lion, installed Rails Installer and now when I follow this tutorial, I get this:

Faraday::Error::ConnectionFailed

SSL_connect returned=1 errno=0 state=SSLv3 read server certificate B: certificate verify failed

Avatar

I agree with this 100%. While I'm sure many will find Devise great (and Ryan's screen cast to back it up), I myself find that authentication is so easy in Rails that I just don't need Devise.

And the has_secure_password works great.

lol. On a different note...anyone here ever do the same time with Spring and Java? OMG what a chore.

Avatar

Why would this be wrong? Another user would see the delete method in the controllers and hopefully be able to discover the initializer. No?

Avatar

Awesome as usual. Seems like the caching would be a perfect fit for Redis. :-)

Avatar

How does this stack up Padrino? As far as performance and ease-of-use?

Avatar

I used this for an asset management app I'm writing.

Instead of countries/states, I use Makes/Models (which belong to an asset).

Anyway, if you are loading a record that has a make/model saved (or a country/state) then the model (state) will be hidden and you will have to change the make (country) to re-enable it. Then you will have to know it's saved value. So I changed it to only hide the model (state) if there is none saved.

coffees.js
jQuery ->
        loaded_model = $('#asset_model_id :selected').text()
        if loaded_model.length < 1
                $('#asset_model_id').parent().parent().hide()
        models = $('#asset_model_id').html()
        $('#asset_make_id').change ->
                make = $('#asset_make_id :selected').text()
                escaped_make = make.replace(/([ #;&,.+*~\':"!^$[\]()=>|\/@])/g, '\\$1')
                options = $(models).filter("optgroup[label='#{escaped_make}']").html()
                if options
                        $('#asset_model_id').html(options)
                        $('#asset_model_id').parent().parent().show()
                else
                        $('#asset_model_id').empty()
                        $('#asset_model_id').parent().parent().hide()
                        

I also used parent().parent() because I am using with SimpleForm

Avatar

Does anyone know how to put the flash messages back in Rails 3.2.1??

<%= debug flash %> is empty.

Avatar

Yes, Ryan is really a spy for the CIA. He watches over us. Seeing our struggles. Then, he releases a podcast on the subject we need most.

I for one welcome our Ryan overlord.

Avatar

What about separating into partials and then:

ruby
<%= render "myview_#{Rails.env}" %>

Then have the following partials:

myview_demo
myview_production

etc...

Avatar

For anyone who is interested, this is my form builder using the Twitter Bootstrap css framework.

https://gist.github.com/1526162

Avatar

Wow. Just finished it. One of your best Ryan. And this is exactly what I was looking for. I am using the Twitter Bootstrap now and I plan on wrapping all of this into a bootstrap form builder.

SWEET!

Avatar

Subscribing is totally worth it. I swear that last night I was literally looking on how to do this in Rails. Then bam. Next day here it is.

Avatar

Nice revision. In fact, I am creating a web app for my company (unbeknownst to them) that connects to a legacy DB and one of our tables has hundreds of rows. This is going to look good on that page!

I am so glad I signed up for your Railscasts. Keep them coming!

Avatar

Could this be used for a single sign-on system? So that I have an authentication app running that passes out authentications to different apps?

Avatar

Awesome episode as usual.

You're right, I prefer using custom logins and authentication over Devise or other methods. I just feel "out of control" when using a plug for something as secure and important as my login.

Keep up the great work!

Avatar

I swear, it seems like every time I'm in the middle of a new project, you release a screen cast on the same subject. Please keep up the great work!