aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMatt Friedman <maf675@gmail.com>2014-04-09 23:17:30 -0700
committerMatt Friedman <maf675@gmail.com>2014-04-09 23:17:30 -0700
commit80bc30214f0d27813b04580a9ddd8243ddb3cfb0 (patch)
tree3b4f278329dd8e006c53f533affaf0743d436906
parent150a45b9434ce908d9bda8b1dc1fa2895cd59578 (diff)
downloadforums-80bc30214f0d27813b04580a9ddd8243ddb3cfb0.tar
forums-80bc30214f0d27813b04580a9ddd8243ddb3cfb0.tar.gz
forums-80bc30214f0d27813b04580a9ddd8243ddb3cfb0.tar.bz2
forums-80bc30214f0d27813b04580a9ddd8243ddb3cfb0.tar.xz
forums-80bc30214f0d27813b04580a9ddd8243ddb3cfb0.zip
[ticket/11098] Fix error reporting on the autologin key pages
PHPBB3-11098
-rw-r--r--phpBB/includes/ucp/ucp_profile.php4
-rw-r--r--phpBB/styles/prosilver/template/ucp_profile_autologin_keys.html8
-rw-r--r--phpBB/styles/subsilver2/template/ucp_profile_autologin_keys.html9
3 files changed, 6 insertions, 15 deletions
diff --git a/phpBB/includes/ucp/ucp_profile.php b/phpBB/includes/ucp/ucp_profile.php
index 76f8988fb9..a14f79f9fd 100644
--- a/phpBB/includes/ucp/ucp_profile.php
+++ b/phpBB/includes/ucp/ucp_profile.php
@@ -679,8 +679,6 @@ class ucp_profile
while ($row = $db->sql_fetchrow($result))
{
$template->assign_block_vars('sessions', array(
- 'errors' => $error,
-
'KEY' => $row['key_id'],
'IP' => $row['last_ip'],
'LOGIN_TIME' => $user->format_date($row['last_login']),
@@ -693,6 +691,8 @@ class ucp_profile
}
$template->assign_vars(array(
+ 'ERROR' => (sizeof($error)) ? implode('<br />', $error) : '',
+
'L_TITLE' => $user->lang['UCP_PROFILE_' . strtoupper($mode)],
'S_HIDDEN_FIELDS' => $s_hidden_fields,
diff --git a/phpBB/styles/prosilver/template/ucp_profile_autologin_keys.html b/phpBB/styles/prosilver/template/ucp_profile_autologin_keys.html
index 13448ead30..6fec0b8aed 100644
--- a/phpBB/styles/prosilver/template/ucp_profile_autologin_keys.html
+++ b/phpBB/styles/prosilver/template/ucp_profile_autologin_keys.html
@@ -5,14 +5,8 @@
<h2>{L_TITLE}</h2>
<div class="panel">
<div class="inner">
- <!-- IF .errors -->
- <p class="error">
- <!-- BEGIN errors -->
- {errors} <br />
- <!-- END errors -->
- </p>
- <!-- ENDIF -->
<p>{L_PROFILE_AUTOLOGIN_KEYS}</p>
+ <!-- IF ERROR --><p class="error">{ERROR}</p><!-- ENDIF -->
<table class="table1">
<thead>
<tr>
diff --git a/phpBB/styles/subsilver2/template/ucp_profile_autologin_keys.html b/phpBB/styles/subsilver2/template/ucp_profile_autologin_keys.html
index 5b7601bc81..3f63319b59 100644
--- a/phpBB/styles/subsilver2/template/ucp_profile_autologin_keys.html
+++ b/phpBB/styles/subsilver2/template/ucp_profile_autologin_keys.html
@@ -4,13 +4,10 @@
<tr>
<th colspan="4">{L_TITLE}</th>
</tr>
-<!-- IF .errors -->
+
+<!-- IF ERROR -->
<tr>
- <td class="row3" colspan="2" align="center"><span class="gensmall error">
- <!-- BEGIN errors -->
- {errors} <br />
- <!-- END errors -->
- </td>
+ <td class="row3" colspan="4" align="center"><span class="genmed error">{ERROR}</span></td>
</tr>
<!-- ENDIF -->