I have one problem when I create the index page.
I have wrote following in index.html.erb:
All Blogs
-
<% @weblogs.each do |page| %>
- <%= link_to page.title, weblog_path(@weblogs) %> <% end %>
and, at first, I create on item and it’s url like this
http://localhost:3000/weblogs/1
It just works fine for me.
But when I’ve created the second item, the url of both 2, became like
this http://localhost:3000/weblogs/1/2
How can I solve this problem, I want the item No.1 is
http://localhost:3000/weblogs/1
and item No.2 should be http://localhost:3000/weblogs/2