Rails for Zombies Level 3, Challenge 5
I'm a novice in both Ruby and Rails, and decided开发者_运维问答 to take basic lessons through Rails for Zombies by Code School. The problem is I cannot get passed level 3, exercise 5. Can someone please help me? This is getting very frustrating, since I do not understand how to link to the EDIT page, as the challenge states...
Thank you so much!
The answer that questioner is looking for
<%= link_to zombie.name, edit_zombie_path(zombie) %>
You should be looking for something like:
<%= link_to "Edit", edit_zombie_path(zombie) %>
Replace 'zombie' with the resource you're working on if needed.
Original Hint #1
You need to link to the zombie's edit page using edit_zombie_path(zombie).
Original Hint #2
A possible correct answer is:
<ul>
<% zombies.each do |zombie| %>
<li>
<%= link_to zombie.name, edit_zombie_path(zombie) %>
</li>
<% end %>
</ul>
精彩评论