This project is archived and is in readonly mode.
link_to with single string argument
-
Ryan Bates
You can use auto_link for this.
auto_link "http://www.rubyonrails.org"That probably isn't as efficient performance wise, so I would still like to see this patch accepted.
-
Chris Barnett
I think this is a good idea, but I'm not sure about the implementation.
I've always been able to do
<%= link_to "Somewhere" %>To create a placeholder for a real link which will be added later. It renders as:
<a href="/path/to/the/current/page">Somewhere</a>This is great for mocking up a page; but with this patch applied, the same link_to becomes:
<a href="Somewhere">Somewhere</a>Placeholder links will now give 404 errors instead of just reloading the page.
Is anyone else using link_to this way?