This project is archived and is in readonly mode.

#4173 ✓resolved
Ravinder Rana

ambigitous behaviour of using link_to helper

Reported by Ravinder Rana | March 14th, 2010 @ 11:32 AM | in 3.0.2

According to the documentation of link_to helper there are two ways of calling it:

1. link_to(name, options = {}, html_options = nil)
    2. link_to(options = {}, html_options = nil) do
         # name

The difference in the two being the ability of not passing name "if the link target is hard to fit into the name parameter."

But the difference doesn't ends there. They need to be called using two different ways. :(

The first one should be called using <%= %> and the second one using <% %>. This seems somewhat awkward. Is there any specific reason for this behaviour? As a user this seems very confusing.

Comments and changes to this ticket

Create your profile

Help contribute to this project by taking a few moments to create your personal profile. Create your profile »

<h2 style="font-size: 14px">Tickets have moved to Github</h2>

The new ticket tracker is available at <a href=""></a>

People watching this ticket