Guest User

Untitled

a guest
May 24th, 2018
87
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.99 KB | None | 0 0
  1. <ul id="vote_history">
  2. <% if @story.votes.empty? %>
  3. <em>No Votes Yet!</em>
  4. <% else %>
  5. <%= render :partial => 'votes/vote',
  6. :collection => @story.votes.latest %>
  7. <% end %>
  8. </ul>
  9. <h2>
  10. <span id="vote_score">
  11. Score: <%= @story.votes.size%>
  12. </span>
  13. <%= @story.name %></h2>
  14. <p class="submitted_by">
  15. Submitted by:
  16. <span><%= @story.user.login %></span>
  17. </p>
  18. <p>
  19. <%= link_to @story.link, @story.link%>
  20. </p>
  21. <% if logged_in? %>
  22. <div id="vote_form">
  23. <% form_remote_tag :url => story_votes_path(@story) do%>
  24. <%= submit_tag 'shove it' %>
  25. <% else %>
  26. <p>
  27. <em>
  28. You would be able to vote for this story if you were
  29. <%= link_to 'logged in', new_session_path %>!
  30. </em>
  31. </p>
  32. <% end %>
  33. </div>
  34. -----------------------------------
  35. the error log:
  36.  
  37. compile error
  38. C:/ruby/cllpx/app/views/stories/show.html.erb:25: syntax error, unexpected kELSE, expecting kEND
  39. else ; _erbout.concat "\n"
  40. ^
  41. C:/ruby/cllpx/app/views/stories/show.html.erb:34: syntax error, unexpected $end, expecting kEND
Add Comment
Please, Sign In to add comment