# Link\_to to open a website

**URL:** <https://www.ruby-forum.com/t/link-to-to-open-a-website/162979>\
**Category:** Rails\
**Created:** [March 16, 2009, 12:18pm UTC](https://www.ruby-forum.com/t/link-to-to-open-a-website/162979 "2009-03-16T12:18:52Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![casper\_the\_ghost](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/c/58956e/32.png) [@casper\_the\_ghost](https://www.ruby-forum.com/u/casper_the_ghost)\
**Post date:** [March 16, 2009, 12:18pm UTC](https://www.ruby-forum.com/t/link-to-to-open-a-website/162979/1 "2009-03-16T12:18:52Z")

</div>

Hello there,

```
 I am using the link_to tag to open a website. I am getting error.

```

I used the following code.

\<%= link\_to “click here”,:action =\>“[http://www.rubyxml.com](http://www.rubyxml.com)” %\>

I am getting the following error

No route matches “/users/http:%2F%[2Fwww.rubyxml.com](http://2Fwww.rubyxml.com)” with  
{:method=\>:get}

Can anybody tell me what i have to do to overcome this problem.

Thanks in advance.

---

<div class="post-metadata">

**Author:** ![casper\_the\_ghost](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/c/58956e/32.png) [@casper\_the\_ghost](https://www.ruby-forum.com/u/casper_the_ghost)\
**Post date:** [March 16, 2009, 1:17pm UTC](https://www.ruby-forum.com/t/link-to-to-open-a-website/162979/2 "2009-03-16T13:17:35Z")

</div>

\<%= link\_to “This should be easy if you RTFM.”, "  
[ActionView::Helpers::UrlHelper](http://api.rubyonrails.org/classes/ActionView/Helpers/UrlHelper.html)" %\>

On Mon, Mar 16, 2009 at 11:43 AM, removed\_email\_address@domain.invalid
