Hi I am very new to RoR and is using Rails 3.2.8 to develop my app. When I am testing my pages, an URL address is automatically displayed after all the links. For instance, <%= link_to 'Home', root_path %> will generate a view in the browser like Home(/), though (/) is not an element that can be found in the page source. I believe this is because I am under development mode? Is there a way to shut this feature off? Thanks!
Here are my codes:
<ul>
<li><%= link_to "Home", root_path %></li>
<li><%= link_to "About", about_path %></li>
<li><%= link_to "Contact", contact_path %></li>
</ul>
And here is the actual html code generated:
<ul>
<li><a href="/">Home</a></li>
<li><a href="/about">About</a></li>
<li><a href="/contact">Contact</a></li>
</ul>
You can see this is perfectly normal...which makes me believe this is not a coding problem. However, when comes into the browser, it is displayed as
- Home(/)
- About(/about)
- Contact(/contact)
I do wish to know where the (/url) part come from... And how to get rid of it.
Here are the JS files I use:
<script src="/assets/application.js?body=1" type="text/javascript"></script>
<script src="/assets/jquery-1.8.0.min.js?body=1" type="text/javascript"></script>
<script src="/assets/jquery-ui-1.8.23.custom.min.js?body=1" type="text/javascript"> </script>
<script src="/assets/autocomplete-rails.js?body=1" type="text/javascript"></script>
<script src="/assets/rails.js?body=1" type="text/javascript"></script>
Rails JS is the rails-ujs script