Re: django and favicon.ico
On Sun, Aug 4, 2013 at 11:56 PM, Mike Dewhirst <miked@dewhirst.com.au> wrote:
On 5/08/2013 4:22am, Tundebabzy wrote:It is a static image no different than any other except that convention says it needs to be in the root of your site.
Hi,
Is there any documentation on how django behaves during a GET
/favicon.ico? In my django 1.4.5 installation with runserver, GET
/favicon.ico redirects to /media/img/favicon; on OpenShift, it redirects
to /media/favicon.ico.
Yeah I agree. I don't know if it was some kind of cache thingy but I noticed that GET /favicon.ico kept on redirecting to /media/img/favicon.ico on runserver. Therefore in my urls.py, I had to catch a url pattern like r'^media/img/favicon\.ico$' then redirect it to '/static/img/favicon.ico' because r'^favicon.ico$' would throw a 404. However after a system reboot, GET /favicon.ico is what it is. Thanks sir.
In production, Apache has /favicon.ico redirecting to where I actually keep it - which is with other static images. It really isn't a Django thing at all. I haven't even thought about trying to get Django dev server to display it. Doesn't seem worthwhile.
Same thing applies to robots.txt
My googlefu has failed me.
--
You received this message because you are subscribed to the Google
Groups "Django users" group.
To unsubscribe from this group and stop receiving emails from it, send
an email to django-users+unsubscribe@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at http://groups.google.com/group/django-users.
For more options, visit https://groups.google.com/groups/opt_out.
--
You received this message because you are subscribed to the Google Groups "Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to django-users+unsubscribe@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at http://groups.google.com/group/django-users.
For more options, visit https://groups.google.com/groups/opt_out.
You received this message because you are subscribed to the Google Groups "Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to django-users+unsubscribe@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at http://groups.google.com/group/django-users.
For more options, visit https://groups.google.com/groups/opt_out.
0 Comments:
Post a Comment
Subscribe to Post Comments [Atom]
<< Home