I’m not really sure if this information is really useful though.
Let us takes into this scenario… if you are using a heavily modded phpbb2 forum, it’s most likely you won’t be able to update your phpbb into a newer version. One possible reason might be that the main coding are altered.
When that happens, then why do you still have the message “Your phpBB is not up to date” in the administrator forum? Might as well took it out.
Take note that this “how to” topic is based on phpBB 2.0.23. The older version might be the similar. I’m not sure about phpbb3 though.
Now, a quick removal would be opening “templates\YOUR_TEMPLATE_NAME\admin\index_body.tpl” and remove the html coding:
<h1>{L_VERSION_INFORMATION}</h1>
{VERSION_INFO}
<br />
There you have it. No more phpBB notification on your administrator index. But wait, haven’t you heard. A good cleaner must know how to remove all traces of clues before leaving the scene of the crime.
So the next part is removing the php codes.
Open “admin\index.php” and remove all these:
// Check for new version
$current_version = explode('.', '2' . $board_config['version']);
$minor_revision = (int) $current_version[2];
$errno = 0;
$errstr = $version_info = ”;
if ($fsock = @fsockopen(’www.phpbb.com’, 80, $errno, $errstr, 10))
{
@fputs($fsock, “GET /updatecheck/20x.txt HTTP/1.1\r\n”);
@fputs($fsock, “HOST: www.phpbb.com\r\n”);
@fputs($fsock, “Connection: close\r\n\r\n”);
$get_info = false;
while (!@feof($fsock))
{
if ($get_info)
{
$version_info .= @fread($fsock, 1024);
}
else
{
if (@fgets($fsock, 1024) == “\r\n”)
{
$get_info = true;
}
}
}
@fclose($fsock);
$version_info = explode(”\n”, $version_info);
$latest_head_revision = (int) $version_info[0];
$latest_minor_revision = (int) $version_info[2];
$latest_version = (int) $version_info[0] . ‘.’ . (int) $version_info[1] . ‘.’ . (int) $version_info[2];
if ($latest_head_revision == 2 && $minor_revision == $latest_minor_revision)
{
$version_info = ‘<p style=”color:green”>’ . $lang['Version_up_to_date'] . ‘</p>’;
}
else
{
$version_info = ‘<p style=”color:red”>’ . $lang['Version_not_up_to_date'];
$version_info .= ‘<br />’ . sprintf($lang['Latest_version_info'], $latest_version) . ‘ ‘ . sprintf($lang['Current_version_info'], ‘2′ . $board_config['version']) . ‘</p>’;
}
}
else
{
if ($errstr)
{
$version_info = ‘<p style=”color:red”>’ . sprintf($lang['Connect_socket_error'], $errstr) . ‘</p>’;
}
else
{
$version_info = ‘<p>’ . $lang['Socket_functions_disabled'] . ‘</p>’;
}
}
$version_info .= ‘<p>’ . $lang['Mailing_list_subscribe_reminder'] . ‘</p>’;
$template->assign_vars(array(
‘VERSION_INFO’ => $version_info,
‘L_VERSION_INFORMATION’ => $lang['Version_information'])
);
…and that’s about it.
Maybe tomorrow, I’ll post about how to remove the update notifications on Wordpress.
Until then, have a nice day. |