jai_kumar
(jai kumar)
January 20, 2016, 3:01pm
1
No route matches {:action=>"index", :controller=>"devise/registrations"}
my application.html.erb
<div class ="link1"> <%= link_to "Home",:action => 'home' >
</div>
<div class ="link1">
<% if userprof_signed_in? %>
<%= link_to "Logout", destroy_userprof_session_path, method: :delete, :class => 'navbar-link' %>
<% else %>
<%= link_to "Sign up", new_userprof_registration_path, :class => 'navbar-link' %> |
<%= link_to "Login", new_userprof_session_path, :class => 'navbar-link' %>
<% end %>
i am able to see home and sign up link but when i am clicking on sign up link i am getting error:No route matches {:action=>"index", :controller=>"devise/registrations"}
need help.
Read the configuration procedure again
jai_kumar
(jai kumar)
January 20, 2016, 4:54pm
3
my devise working once i remove home link from application.html…
my devise working once i remove home link from application.html..
Read the configuration procedure again
>
> No route matches {:action=>"index", :controller=>"devise/registrations"}
>
>
> my application.html.erb
>
>
> <div class ="link1">
> <%= link_to "Home",:action => 'home' >
That's your problem -- illegal route. Maybe you want link_to( "Home", :root ) instead.
If you haven't read Routing from the Outside In lately, now is a perfect time to do so. Rails Routing from the Outside In — Ruby on Rails Guides
Walter