aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--phpBB/docs/AUTHORS2
-rw-r--r--phpBB/includes/acp/acp_groups.php1
-rw-r--r--phpBB/includes/functions_display.php14
-rw-r--r--phpBB/includes/functions_template.php19
-rw-r--r--phpBB/includes/template.php60
-rw-r--r--phpBB/includes/ucp/ucp_groups.php1
-rw-r--r--phpBB/language/en/acp/common.php2
-rw-r--r--phpBB/styles/prosilver/template/mcp_post.html5
-rw-r--r--phpBB/styles/prosilver/template/search_body.html2
-rw-r--r--phpBB/styles/prosilver/template/ucp_pm_viewmessage.html7
-rw-r--r--phpBB/styles/subsilver2/template/mcp_post.html2
11 files changed, 75 insertions, 40 deletions
diff --git a/phpBB/docs/AUTHORS b/phpBB/docs/AUTHORS
index f50044f944..9452c21ae7 100644
--- a/phpBB/docs/AUTHORS
+++ b/phpBB/docs/AUTHORS
@@ -6,7 +6,7 @@
/* *\
/* ********************************************************************** *\
-Please see: http://www.phpbb.com/about/ for a list of all the people currently
+Please see: http://www.phpbb.com/about/team/ for a list of all the people currently
involved in phpBB.
phpBB Project Manager : theFinn (James Atkinson)
diff --git a/phpBB/includes/acp/acp_groups.php b/phpBB/includes/acp/acp_groups.php
index 128cea2cb9..cbf46a1dc1 100644
--- a/phpBB/includes/acp/acp_groups.php
+++ b/phpBB/includes/acp/acp_groups.php
@@ -558,6 +558,7 @@ class acp_groups
'S_RANK_OPTIONS' => $rank_options,
'S_GROUP_OPTIONS' => group_select_options(false, false, (($user->data['user_type'] == USER_FOUNDER) ? false : 0)),
+ 'AVATAR' => $avatar_img,
'AVATAR_IMAGE' => $avatar_img,
'AVATAR_MAX_FILESIZE' => $config['avatar_filesize'],
'AVATAR_WIDTH' => (isset($group_row['group_avatar_width'])) ? $group_row['group_avatar_width'] : '',
diff --git a/phpBB/includes/functions_display.php b/phpBB/includes/functions_display.php
index 1ab6dda638..23e2cd4106 100644
--- a/phpBB/includes/functions_display.php
+++ b/phpBB/includes/functions_display.php
@@ -287,24 +287,26 @@ function display_forums($root_data = '', $display_moderators = true, $return_mod
{
foreach ($subforums[$forum_id] as $subforum_id => $subforum_row)
{
- // Update unread information if needed
- if (!$forum_unread)
- {
- $forum_unread = (isset($forum_tracking_info[$subforum_id]) && $subforum_row['orig_forum_last_post_time'] > $forum_tracking_info[$subforum_id]) ? true : false;
- }
+ $subforum_unread = (isset($forum_tracking_info[$subforum_id]) && $subforum_row['orig_forum_last_post_time'] > $forum_tracking_info[$subforum_id]) ? true : false;
if ($subforum_row['display'] && $subforum_row['name'])
{
$subforums_list[] = array(
'link' => append_sid("{$phpbb_root_path}viewforum.$phpEx", 'f=' . $subforum_id),
'name' => $subforum_row['name'],
- 'unread' => $forum_unread,
+ 'unread' => $subforum_unread,
);
}
else
{
unset($subforums[$forum_id][$subforum_id]);
}
+
+ // If one subforum is unread the forum gets unread too...
+ if ($subforum_unread)
+ {
+ $forum_unread = true;
+ }
}
$l_subforums = (sizeof($subforums[$forum_id]) == 1) ? $user->lang['SUBFORUM'] . ': ' : $user->lang['SUBFORUMS'] . ': ';
diff --git a/phpBB/includes/functions_template.php b/phpBB/includes/functions_template.php
index 4e5b46c3f7..f37148658b 100644
--- a/phpBB/includes/functions_template.php
+++ b/phpBB/includes/functions_template.php
@@ -54,7 +54,7 @@ class template_compile
* Load template source from file
* @access private
*/
- function _tpl_load_file($handle)
+ function _tpl_load_file($handle, $store_in_db = false)
{
// Try and open template for read
if (!file_exists($this->template->files[$handle]))
@@ -66,6 +66,23 @@ class template_compile
// Actually compile the code now.
$this->compile_write($handle, $this->template->compiled_code[$handle]);
+
+ // Store in database if required...
+ if ($store_in_db)
+ {
+ global $db, $user;
+
+ $sql_ary = array(
+ 'template_id' => $user->theme['template_id'],
+ 'template_filename' => $this->template->filename[$handle],
+ 'template_included' => '',
+ 'template_mtime' => time(),
+ 'template_data' => trim(@file_get_contents($this->template->files[$handle])),
+ );
+
+ $sql = 'INSERT INTO ' . STYLES_TEMPLATE_DATA_TABLE . ' ' . $db->sql_build_array('INSERT', $sql_ary);
+ $db->sql_query($sql);
+ }
}
/**
diff --git a/phpBB/includes/template.php b/phpBB/includes/template.php
index 259874488d..3326852ee7 100644
--- a/phpBB/includes/template.php
+++ b/phpBB/includes/template.php
@@ -222,44 +222,56 @@ class template
if (isset($user->theme['template_storedb']) && $user->theme['template_storedb'])
{
- $sql = 'SELECT * FROM ' . STYLES_TEMPLATE_DATA_TABLE . '
+ $sql = 'SELECT *
+ FROM ' . STYLES_TEMPLATE_DATA_TABLE . '
WHERE template_id = ' . $user->theme['template_id'] . "
AND (template_filename = '" . $db->sql_escape($this->filename[$handle]) . "'
OR template_included LIKE '%" . $db->sql_escape($this->filename[$handle]) . ":%')";
$result = $db->sql_query($sql);
+ $row = $db->sql_fetchrow($result);
- while ($row = $db->sql_fetchrow($result))
+ if ($row)
{
- if ($row['template_mtime'] < filemtime($phpbb_root_path . 'styles/' . $user->theme['template_path'] . '/template/' . $row['template_filename']))
+ do
{
- if ($row['template_filename'] == $this->filename[$handle])
+ if ($row['template_mtime'] < filemtime($phpbb_root_path . 'styles/' . $user->theme['template_path'] . '/template/' . $row['template_filename']))
{
- $compile->_tpl_load_file($handle);
+ if ($row['template_filename'] == $this->filename[$handle])
+ {
+ $compile->_tpl_load_file($handle);
+ }
+ else
+ {
+ $this->files[$row['template_filename']] = $this->root . '/' . $row['template_filename'];
+ $compile->_tpl_load_file($row['template_filename']);
+ unset($this->compiled_code[$row['template_filename']]);
+ unset($this->files[$row['template_filename']]);
+ }
}
- else
+
+ if ($row['template_filename'] == $this->filename[$handle])
{
- $this->files[$row['template_filename']] = $this->root . '/' . $row['template_filename'];
- $compile->_tpl_load_file($row['template_filename']);
- unset($this->compiled_code[$row['template_filename']]);
- unset($this->files[$row['template_filename']]);
+ $this->compiled_code[$handle] = $compile->compile(trim($row['template_data']));
+ $compile->compile_write($handle, $this->compiled_code[$handle]);
}
- }
-
- if ($row['template_filename'] == $this->filename[$handle])
- {
- $this->compiled_code[$handle] = $compile->compile(trim($row['template_data']));
- $compile->compile_write($handle, $this->compiled_code[$handle]);
- }
- else
- {
- // Only bother compiling if it doesn't already exist
- if (!file_exists($this->cachepath . str_replace('/', '.', $row['template_filename']) . '.' . $phpEx))
+ else
{
- $this->filename[$row['template_filename']] = $row['template_filename'];
- $compile->compile_write($row['template_filename'], $compile->compile(trim($row['template_data'])));
- unset($this->filename[$row['template_filename']]);
+ // Only bother compiling if it doesn't already exist
+ if (!file_exists($this->cachepath . str_replace('/', '.', $row['template_filename']) . '.' . $phpEx))
+ {
+ $this->filename[$row['template_filename']] = $row['template_filename'];
+ $compile->compile_write($row['template_filename'], $compile->compile(trim($row['template_data'])));
+ unset($this->filename[$row['template_filename']]);
+ }
}
}
+ while ($row = $db->sql_fetchrow($result));
+ }
+ else
+ {
+ // Try to load from filesystem and instruct to insert into the styles table...
+ $compile->_tpl_load_file($handle, true);
+ return false;
}
$db->sql_freeresult($result);
diff --git a/phpBB/includes/ucp/ucp_groups.php b/phpBB/includes/ucp/ucp_groups.php
index 720d1f9467..5445d661b7 100644
--- a/phpBB/includes/ucp/ucp_groups.php
+++ b/phpBB/includes/ucp/ucp_groups.php
@@ -679,6 +679,7 @@ class ucp_groups
'S_DESC_SMILIES_CHECKED'=> $group_desc_data['allow_smilies'],
'S_RANK_OPTIONS' => $rank_options,
+ 'AVATAR' => $avatar_img,
'AVATAR_IMAGE' => $avatar_img,
'AVATAR_MAX_FILESIZE' => $config['avatar_filesize'],
'AVATAR_WIDTH' => (isset($group_row['group_avatar_width'])) ? $group_row['group_avatar_width'] : '',
diff --git a/phpBB/language/en/acp/common.php b/phpBB/language/en/acp/common.php
index 350ba390e2..7d88571824 100644
--- a/phpBB/language/en/acp/common.php
+++ b/phpBB/language/en/acp/common.php
@@ -272,7 +272,7 @@ $lang = array_merge($lang, array(
// PHP info
$lang = array_merge($lang, array(
- 'ACP_PHP_INFO_EXPLAIN' => 'This page lists information on the version of PHP installed on this server. It includes details of loaded modules, available variables and default settings. This information may be useful when diagnosing problems. Please be aware that some hosting companies will limit what information is displayed here for security reasons. You are advised to not give out any details on this page except when asked by <a href="http://www.phpbb.com/about/">official team members</a> on the support forums.',
+ 'ACP_PHP_INFO_EXPLAIN' => 'This page lists information on the version of PHP installed on this server. It includes details of loaded modules, available variables and default settings. This information may be useful when diagnosing problems. Please be aware that some hosting companies will limit what information is displayed here for security reasons. You are advised to not give out any details on this page except when asked by <a href="http://www.phpbb.com/about/team/">official team members</a> on the support forums.',
'NO_PHPINFO_AVAILABLE' => 'The PHP informations are unable to be determined. Phpinfo() has been disabled for security reasons.',
));
diff --git a/phpBB/styles/prosilver/template/mcp_post.html b/phpBB/styles/prosilver/template/mcp_post.html
index 446491a878..fd23bb3b74 100644
--- a/phpBB/styles/prosilver/template/mcp_post.html
+++ b/phpBB/styles/prosilver/template/mcp_post.html
@@ -138,11 +138,12 @@
</div>
<!-- ENDIF -->
-<!-- IF S_MCP_QUEUE or S_MCP_REPORTS or RETURN_TOPIC -->
+
+<!-- IF S_MCP_QUEUE or S_MCP_REPORT or RETURN_TOPIC -->
<div class="panel">
<div class="inner"><span class="corners-top"><span></span></span>
- <p><!-- IF S_MCP_QUEUE -->{RETURN_QUEUE} | {RETURN_TOPIC_SIMPLE} | {RETURN_POST}<!-- ELSEIF S_MCP_REPORTS -->{RETURN_REPORTS}<!-- ELSE -->{RETURN_TOPIC}<!-- ENDIF --></p>
+ <p><!-- IF S_MCP_QUEUE -->{RETURN_QUEUE} | {RETURN_TOPIC_SIMPLE} | {RETURN_POST}<!-- ELSEIF S_MCP_REPORT -->{RETURN_REPORTS} | <a href="{U_VIEW_TOPIC}">{L_VIEW_TOPIC}</a><!-- ELSE -->{RETURN_TOPIC}<!-- ENDIF --></p>
<span class="corners-bottom"><span></span></span></div>
</div>
diff --git a/phpBB/styles/prosilver/template/search_body.html b/phpBB/styles/prosilver/template/search_body.html
index 525d9820a2..95390c2545 100644
--- a/phpBB/styles/prosilver/template/search_body.html
+++ b/phpBB/styles/prosilver/template/search_body.html
@@ -44,7 +44,7 @@
<dl>
<dt><label for="sf1">{L_SEARCH_WITHIN}:</label></dt>
<dd><label for="sf1"><input type="radio" name="sf" id="sf1" value="all" checked="checked" /> {L_SEARCH_TITLE_MSG}</label></dd>
- <dd><label for="sf2"><input type="radio" name="sf" id="sf2" value="msgonly" checked="checked" /> {L_SEARCH_MSG_ONLY}</label></dd>
+ <dd><label for="sf2"><input type="radio" name="sf" id="sf2" value="msgonly" /> {L_SEARCH_MSG_ONLY}</label></dd>
<dd><label for="sf3"><input type="radio" name="sf" id="sf3" value="titleonly" /> {L_SEARCH_TITLE_ONLY}</label></dd>
<dd><label for="sf4"><input type="radio" name="sf" id="sf4" value="firstpost" /> {L_SEARCH_FIRST_POST}</label></dd>
</dl>
diff --git a/phpBB/styles/prosilver/template/ucp_pm_viewmessage.html b/phpBB/styles/prosilver/template/ucp_pm_viewmessage.html
index 8af9f2d716..5fb6e2c573 100644
--- a/phpBB/styles/prosilver/template/ucp_pm_viewmessage.html
+++ b/phpBB/styles/prosilver/template/ucp_pm_viewmessage.html
@@ -9,11 +9,12 @@
<div class="inner"><span class="corners-top"><span></span></span>
<div class="postbody">
+
<!-- IF U_DELETE or U_EDIT or U_QUOTE -->
<ul class="profile-icons">
- <!-- IF U_EDIT --><li class="edit-icon"><a href="{U_EDIT}" title="{L_POST_EDIT_PM}"><span>{L_EDIT_PM}</span></a></li><!-- ENDIF -->
- <!-- IF U_DELETE --><li class="delete-icon"><a href="{U_DELETE}" title="{L_DELETE_MESSAGE}"><span>{L_DELETE_PM}</span></a></li><!-- ENDIF -->
- <!-- IF U_QUOTE --><li class="quote-icon"><a href="{U_QUOTE}" title="{L_POST_QUOTE_PM}"><span>{L_QUOTE_PM}</span></a></li><!-- ENDIF -->
+ <!-- IF U_EDIT --><li class="edit-icon"><a href="{U_EDIT}" title="{L_POST_EDIT_PM}"><span>{L_POST_EDIT_PM}</span></a></li><!-- ENDIF -->
+ <!-- IF U_DELETE --><li class="delete-icon"><a href="{U_DELETE}" title="{L_DELETE_MESSAGE}"><span>{L_DELETE_MESSAGE}</span></a></li><!-- ENDIF -->
+ <!-- IF U_QUOTE --><li class="quote-icon"><a href="{U_QUOTE}" title="{L_POST_QUOTE_PM}"><span>{L_POST_QUOTE_PM}</span></a></li><!-- ENDIF -->
</ul>
<!-- ENDIF -->
diff --git a/phpBB/styles/subsilver2/template/mcp_post.html b/phpBB/styles/subsilver2/template/mcp_post.html
index 858e4c5a17..86669957fe 100644
--- a/phpBB/styles/subsilver2/template/mcp_post.html
+++ b/phpBB/styles/subsilver2/template/mcp_post.html
@@ -45,7 +45,7 @@
<th colspan="2" align="center">{L_POST_DETAILS}</th>
</tr>
<tr>
- <td class="row3" colspan="2" align="center"><span class="gensmall"><!-- IF S_MCP_QUEUE -->{RETURN_QUEUE} | {RETURN_TOPIC_SIMPLE} | {RETURN_POST}<!-- ELSEIF S_MCP_REPORT -->{RETURN_REPORTS}<!-- ELSE -->{RETURN_TOPIC}<!-- ENDIF --></span></td>
+ <td class="row3" colspan="2" align="center"><span class="gensmall"><!-- IF S_MCP_QUEUE -->{RETURN_QUEUE} | {RETURN_TOPIC_SIMPLE} | {RETURN_POST}<!-- ELSEIF S_MCP_REPORT -->{RETURN_REPORTS} | <a href="{U_VIEW_TOPIC}">{L_VIEW_TOPIC}</a><!-- ELSE -->{RETURN_TOPIC}<!-- ENDIF --></span></td>
</tr>
<tr>
<td class="row1"><b class="gen">{L_POST_SUBJECT}: </b></td>