Tomorrow is Sierra‘s opening day, and we plan to be there! Oh yeah! We will see how the Smart car performs at the mountains. I don’t think the back gates or West Bowl are open yet, but I don’t care, just riding down a bit of Sugar-n-Spice and Lower Main will already be hella fun.
Monthly Archives: December 2008
Just added Facebook Connect to this blog
Sociable released a WordPress plugin to link up WordPress blogs to Facebook with Facbeook Connect. I just installed it, took about 5 minutes, and it works great. It allows you to link your FB account to this blog, so you can post comments with your FB identity. Your comments are automatically approved if you posted with fbconnect. You also get to use the familiar fb:multi-friend-selector to invite friends to this blog.
Flickr user MSM posted some 5dm2 test videos
Not bad!
RESTful in-place edit in Rails and jRails/jQuery
I’ve been using jRails in my recent Rails projects, the original Rails in-place editing plugin uses script.aculo.us, there is a jRails version of it, but neither of them is RESTful – they both create extra actions to update the in-place edit fields.
I found janv’s rest_in_place plugin and it uses the default update action to update the field, so no routes modifications are necessary. I had some problems with the plugin at first but after a pull-request correspondence the plugin now works well. Here are the highlights on how to use it, keep in mind that I use HAML.
The plugin’s init.rb doesn’t load anything for you, so you have to go into your application layout and include the js file:
= javascript_include_tag 'jquery.rest_in_place.js'
If you have CSRF protection on, this plugin also requires you to set a javascript var. If you have jRails it automatically append the token in ajax requests, but then you would have to modify the plugin a bit to get it to work.
:javascript rails_authenticity_token = '#{form_authenticity_token}'
In your controller’s show action, handle the javascript response:
def show respond_to do |format| format.html # show.html.erb format.js { render :json => @model } end end
then you can render the helper in the views:
- div_for @model do %p = label_tag "Name" %br %span.rest_in_place{ :attribute =>'name' } =h @model.name %p = label_tag "Location" %br %span.rest_in_place{ :attribute => 'location' } =h @model.location
37signals also saw the benefits of AWS
37signals moved TaDaList to run on pretty much the same things I’m using: EC2, EBS, Elastic IPs, Apache, Passenger. They also started from the same Ubuntu Intrepid images. 🙂
Joshua posted more info on their setup in the comments section of the blog post:
Joshua Sierles 28 Nov 08
Matt,
Our custom image is based on the Ubuntu Intrepid images from Alestic. We install useful EC2 gems and base packages, bundle, then provision each instance by role. Working with EC2 is so easy, we don?t see much value in using a third-party provider for our scale.
Yaroslav,
EBS and Elastic IPs were the primary motivation for moving to EC2 . We use EBS extensively: for MySQL data, logs and local repository mirrors. Performance so far is excellent. Snapshotting volumes is a breeze and makes setting up MySQL slaves and staging environments really easy.
[From Ta-da List on Rails 2.2, Passenger And EC2 – (37signals)]