# Url detection

**URL:** <https://www.ruby-forum.com/t/url-detection/105125>\
**Category:** Rails\
**Created:** [May 25, 2007, 11:25pm UTC](https://www.ruby-forum.com/t/url-detection/105125 "2007-05-25T23:25:50Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![comike01](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/c/3da27b/32.png) [@comike01](https://www.ruby-forum.com/u/comike01)\
**Post date:** [May 25, 2007, 11:25pm UTC](https://www.ruby-forum.com/t/url-detection/105125/1 "2007-05-25T23:25:50Z")

</div>

Kind of new with rails, but is there a simple way to detect a sites  
URL? thanks.

---

<div class="post-metadata">

**Author:** ![comike01](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/c/3da27b/32.png) [@comike01](https://www.ruby-forum.com/u/comike01)\
**Post date:** [May 28, 2007, 1:44pm UTC](https://www.ruby-forum.com/t/url-detection/105125/2 "2007-05-28T13:44:09Z")

</div>

> Kind of new with rails, but is there a simple way to detect a sites  
> URL? thanks.  
> rails comes with great documentation:

[http://api.rubyonrails.org/](http://api.rubyonrails.org/)

the way to use it is simple: take one of the words in your question  
and try to find a method in the method list that matches this word.  
This works for about 80% of any question, at least for me 🙂

if you don’t have a browser, try this:

url\_for :only\_path=\>false
