0

I tried implementing the features in RailsCast 147 Sortable Lists and 302 In-Place Editing, but after having followed every step along the way, the effects that showed on Ryan's screen was different from mine.

In the case of 302 In-Place Editing, clicking on the supposedly in-place-editing-enabled text had no effects!

I had simple code to implement the best_in_place in views/users/show.html.erb

<h1>
  <%= gravatar_for @user %>
  <%= @user.name %>
</h1>

<% firstname = @user.name.split(" ")[0] %>
<p>
    <%= best_in_place @user, :email %>
</p>

And in the case of 147 Sortable Lists, the line <%= sortable_element("faq") %> gave me an undefined method 'sortable_element' error.

Please help!

jytoronto
  • 558
  • 3
  • 10
  • 18
  • What version of rails are you using? That sortable_element method seems to have been removed somewhere in 3.0. – Brian Jul 17 '13 at 14:31
  • thanks for the heads up, any idea how I can get the in-line-editing to work? – jytoronto Jul 17 '13 at 18:27
  • Ryan usually provides source code downloads for his RailsCasts. I would suggest you download the accompanying source code and compare your code with his. – Richard Cook Jul 17 '13 at 21:29

1 Answers1

0

It's impossible to diagnose the issue without seeing the code that doesn't behave as expected for the first part of your question.

sortable_element was deprecated in Rails 3.0.9, which explains the second issue.

Chris Cashwell
  • 22,308
  • 13
  • 63
  • 94