- xml - AJAX/Jquery XML 解析
- 具有多重继承的 XML 模式
- .net - 枚举序列化 Json 与 XML
- XML 简单类型、简单内容、复杂类型、复杂内容
谁能告诉我如何更改 Ruby on Rails 错误消息“很抱歉,出了点问题。”我只是想更改此错误的文本,但出于某种原因,无法弄清楚此页面/文本所在的位置以便我可以修改它。
提前感谢您的宝贵时间。
耐多药
最佳答案
代码位于public/500.html
。您可以根据需要更改它。
#public/500.html
<!DOCTYPE html>
<html>
<head>
<title>We're sorry, but something went wrong (500)</title>
<meta name="viewport" content="width=device-width,initial-scale=1">
<style>
body {
background-color: #EFEFEF;
color: #2E2F30;
text-align: center;
font-family: arial, sans-serif;
margin: 0;
}
div.dialog {
width: 95%;
max-width: 33em;
margin: 4em auto 0;
}
div.dialog > div {
border: 1px solid #CCC;
border-right-color: #999;
border-left-color: #999;
border-bottom-color: #BBB;
border-top: #B00100 solid 4px;
border-top-left-radius: 9px;
border-top-right-radius: 9px;
background-color: white;
padding: 7px 12% 0;
box-shadow: 0 3px 8px rgba(50, 50, 50, 0.17);
}
h1 {
font-size: 100%;
color: #730E15;
line-height: 1.5em;
}
div.dialog > p {
margin: 0 0 1em;
padding: 1em;
background-color: #F7F7F7;
border: 1px solid #CCC;
border-right-color: #999;
border-left-color: #999;
border-bottom-color: #999;
border-bottom-left-radius: 4px;
border-bottom-right-radius: 4px;
border-top-color: #DADADA;
color: #666;
box-shadow: 0 3px 8px rgba(50, 50, 50, 0.17);
}
</style>
</head>
<body>
<!-- This file lives in public/500.html -->
<div class="dialog">
<div>
<h1>We're sorry, but something went wrong.</h1>
</div>
<p>If you are the application owner check the logs for more information.</p>
</div>
</body>
</html>
或
您可以使用自己的动态错误页面自定义错误消息。看看这个tutorial关于如何实现它。
关于ruby - 如何更改 Rails 错误消息文本 "We' 抱歉,出了点问题。”,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/33636074/
当我们尝试播放录制的音频和视频时,我们没有得到针对警告的任何解决方案。警告是 sorry this video is not valid for streaming to this device'.
我在 Gitlab 中遇到以下错误: Sorry, we cannot cherry-pick this merge request automatically. This merge request
我正在尝试从 Solr 中的 Oracle 数据库索引我的数据。为此,我在 Solr 中创建了一个名为“orca”的核心。我的数据库表名称是 school,它有 id、name 和 prcipal 三
我的本地服务器中有一个视频文件。我正在为我的 android 代码提供视频文件的 URL。我在 Htdocs 文件夹的视频文件夹中有视频文件。我在 stackoverflow 上查找了相同的问题,
我很困惑,我已经集成了定期支付系统。 它在 3 天前运行良好。第 2 天我收到错误 Sorry — your last action could not be completed When I am
我在我的应用程序中使用 VideoPlayer。它播放一切正常,但是当我想在媒体播放器的栏上滚动时,通常会出现错误:抱歉,无法播放该视频。我必须重新启动视频才能再次观看。我所发现的是,如果我停止视频并
我的测试调用名称是“Mrs Tang”,所以我输入“Talk to Mrs Tang”,但它响应“对不起,此操作在模拟中不可用”... 有谁知道我该如何解决这个错误? 最佳答案 根据doc : Tur
我试图在登录后将 Laravel 页面重定向到另一个主页,但它每次都会将我重定向到 home 。我所做的是:我将 protected $redirectTo = 的值从 home 更改为 protec
我收到此错误消息“抱歉,您无权访问此页面”。当我转到我的页面http://localhost/wordpressstuff/wp-admin/options-general.php?page=edit
我是 MYSQL 新手,在执行给定过程时遇到问题。它在 SQL 版本 5.7.28 上运行完美,但在 SQL 5.6.41 上抛出以下错误 ERROR: SQL query: create proce
尝试编写一个程序,将 char 数组 (ch) 的值从 65 分配到 90。然后我尝试像这样打印: A, B, C, D, E, F, G, H, I, J, K, L, M, N, O, P
function w_3_wid(str, wid03) { var word = new Array(); var i; var ret = ''; word = str.s
我有一个固定宽度的父 div,我在其中向右浮动带有标签的图像: 期望文本环绕图像。 不幸的是,IE7 将图像 float 到父 div 的 RHS 边界之外(参见 http://hort
我用Microsoft Bot Framework(Builder v3.12.2.4,目前最新版本)开发了一个机器人。实际上,我将所有库都更新到了最新版本,还有 AdaptiveCards,最新的
我的.htaccess: Options -MultiViews RewriteEngine On RewriteBase /silex/web RewriteCond %{REQUEST_FILE
迁移到新主机后,我的一个站点上出现奇怪的错误消息 Sorry, you are not allowed to edit this item. 我发现的解决方案但对我不起作用的是: 我检查了所有前缀内容
我已使用 wc-variations-radio-buttons-master 将下拉菜单更改为单选按钮 不同的颜色实际上也是单选按钮。 当前link产品有12这种有产品而不是其他的变化。我可以解释的
我尝试从网络浏览器访问 ftp,但收到以下错误:421 抱歉,此服务器不接受明文 session 。有什么想法吗? 最佳答案 “421 抱歉,此服务器不接受明文 session ”表示服务器正在使用“
friend , 我正在使用以下代码在我的应用程序中显示 mp4 视频并面临以下问题 我在 google 和 stackoverflow 上看到了很多与这个问题相关的帖子,但每个人都给出了自己的建议,
我正在尝试使用 mysql 导入在 Debian 上配置 SOLR。 Solr 正在运行,我可以访问 http://localhost:8983/solr/ 上的管理区域但是我无法在所选核心下进行数据
我是一名优秀的程序员,十分优秀!