# Favicon.ico and mongrel

**URL:** <https://www.ruby-forum.com/t/favicon-ico-and-mongrel/123192>\
**Category:** Rails\
**Created:** [December 14, 2007, 8:33pm UTC](https://www.ruby-forum.com/t/favicon-ico-and-mongrel/123192 "2007-12-14T20:33:22Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![evronm](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/e/f1d935/32.png) [@evronm](https://www.ruby-forum.com/u/evronm)\
**Post date:** [December 14, 2007, 8:33pm UTC](https://www.ruby-forum.com/t/favicon-ico-and-mongrel/123192/1 "2007-12-14T20:33:22Z")

</div>

Hey folks,

I have a bit of a frustrating problem with requests for favicon.ico  
generating all sorts of errors in my log files. The problem is that the  
default routes.rb file has the following line:

```
map.connect ':controller/:action/:id.:format'

```

If I’m requesting [http://localhost:3000/user/list/3](http://localhost:3000/user/list/3) then firefox will  
automatically generate a request for the favicon.ico file at  
[http://localhost:3000/user/list/favicon.ico](http://localhost:3000/user/list/favicon.ico) .

This gets matched by the above route and Rails throws an error like  
this:

```
ActiveRecord::RecordNotFound (Couldn't find User with ID=favicon):

```

How do I get Rails to match favicon requests properly? Alternatively  
how can I get mongrel to realize that favicon.ico requests always need  
to go to the /public folder.

Maybe it’s just ocd, but I’d like to keep my dev logs clear of all these  
crappy errors.

Thanks for your help,

Mike

---

<div class="post-metadata">

**Author:** ![evronm](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/e/f1d935/32.png) [@evronm](https://www.ruby-forum.com/u/evronm)\
**Post date:** [December 14, 2007, 8:35pm UTC](https://www.ruby-forum.com/t/favicon-ico-and-mongrel/123192/2 "2007-12-14T20:35:19Z")

</div>

Links should be [https://localhost:3000/user/show](https://localhost:3000/user/show) not /list

Mike

---

<div class="post-metadata">

**Author:** ![evronm](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/e/f1d935/32.png) [@evronm](https://www.ruby-forum.com/u/evronm)\
**Post date:** [December 14, 2007, 9:35pm UTC](https://www.ruby-forum.com/t/favicon-ico-and-mongrel/123192/3 "2007-12-14T21:35:28Z")

</div>

Hello Mike,

you might want to add one of the following lines to your HTML header:

Kind regards Nicolai
