gpt4 book ai didi

ruby-on-rails-3 - 如何摆脱与 favicon.ico 相关的路由错误

转载 作者:行者123 更新时间:2023-12-04 15:13:26 27 4
gpt4 key购买 nike

关于如何摆脱这个错误的任何想法。

在 2012-12-18 11:20:59 +0000 开始为 132.175.48.49 获取“/favicon.ico”

ActionController::RoutingError (No route matches [GET] "/favicon.ico"):
actionpack (3.2.8) lib/action_dispatch/middleware/debug_exceptions.rb:21:in `call'
actionpack (3.2.8) lib/action_dispatch/middleware/show_exceptions.rb:56:in `call'
railties (3.2.8) lib/rails/rack/logger.rb:26:in `call_app'
railties (3.2.8) lib/rails/rack/logger.rb:16:in `call'
actionpack (3.2.8) lib/action_dispatch/middleware/request_id.rb:22:in `call'
rack (1.4.1) lib/rack/methodoverride.rb:21:in `call'
rack (1.4.1) lib/rack/runtime.rb:17:in `call'

最佳答案

您可能有这样一行(很可能在您的 application.html.erb 或其他一些模板中):

<link href="/favicon.ico" rel="shortcut icon" />

如果这样做,只需将其更改为:
<link href="/assets/favicon.ico" rel="shortcut icon" />

关于ruby-on-rails-3 - 如何摆脱与 favicon.ico 相关的路由错误,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/13938303/

27 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com