Thoul
VIP

Joined: 30 Jul 2002
Posts: 17676
Location: USA
|
Posted: November 23rd 2004, 7:43 pm Post subject: Using Templates With Different phpBB Versions |
|
|
As you probably know, there have been many versions of phpBB 2.0 released, ranging from 2.0.0 to 2.0.11 (as of this posting). Occasionally during these releases, some changes have been made that can create compatibility problems between certain versions of phpBB and templates downloaded from the phpBBHacks.com Templates Database. This topic is a guide to dealing with these compatibility issues.
Missing Username Fields
This compatibility issue affects any template in the Templates Database listed as compatible with phpBB 2.0.5 or later. You may find that after installing one of these templates on a forum using phpBB 2.0.0 - 2.0.4, the username field does not appear in the registration form. There are several ways to fix the missing field problem. The best way to restore the field is to upgrade to the latest version of phpBB.
Another method is to make a minor update based on code from phpBB 2.0.5. Making the change below should restore the field on every template that is affected.
| Code:
|
##
##----------[ OPEN ]-------------------------------------
##
includes/usercp_register.php
##
##----------[ FIND ]-------------------------------------
##
if ( $mode == 'editprofile' )
{
$template->assign_block_vars('switch_edit_profile', array());
}
##
##----------[ AFTER, ADD ]-------------------------------
##
if ( ($mode == 'register') || ($board_config['allow_namechange']) )
{
$template->assign_block_vars('switch_namechange_allowed', array());
}
else
{
$template->assign_block_vars('switch_namechange_disallowed', array());
}
|
There are a couple of other possible fixes that deal with editing or replacing the profile_add_body.tpl file of the template. These can lead to several other incompatibility and design problems and are not recommended.
Visual Confirmation
This compatibility issue affects any template in the Templates Database listed as compatible with phpBB 2.0.10 or earlier when installed on a phpBB 2.0.11 or later forum. In phpBB 2.0.11, a visual confirmation system was added to phpBB's features and certain template file changes are needed to support this feature. These changes, based on the subSilver template, are as follows.
| Code:
|
##
##----------[ OPEN ]-------------------------------------
##
templates/subSilver/admin/board_config_body.tpl
##
##----------[ FIND ]-------------------------------------
##
<td class="row2"><input type="radio" name="require_activation" value="{ACTIVATION_NONE}" {ACTIVATION_NONE_CHECKED} />{L_NONE} <input type="radio" name="require_activation" value="{ACTIVATION_USER}" {ACTIVATION_USER_CHECKED} />{L_USER} <input type="radio" name="require_activation" value="{ACTIVATION_ADMIN}" {ACTIVATION_ADMIN_CHECKED} />{L_ADMIN}</td>
</tr>
<tr>
##
##----------[ AFTER, ADD ]-------------------------------
##
<td class="row1">{L_VISUAL_CONFIRM}<br /><span class="gensmall">{L_VISUAL_CONFIRM_EXPLAIN}</span></td>
<td class="row2"><input type="radio" name="enable_confirm" value="1" {CONFIRM_ENABLE} />{L_YES} <input type="radio" name="enable_confirm" value="0" {CONFIRM_DISABLE} />{L_NO}</td>
</tr>
<tr>
|
Please note that this second change may already be present in your template.
| Code:
|
##
##----------[ OPEN ]-------------------------------------
##
templates/subSilver/profile_add_body.tpl
##
##----------[ FIND ]-------------------------------------
##
<tr>
<td class="row1"><span class="gen">{L_CONFIRM_PASSWORD}: * </span><br />
<span class="gensmall">{L_PASSWORD_CONFIRM_IF_CHANGED}</span></td>
<td class="row2">
<input type="password" class="post" style="width: 200px" name="password_confirm" size="25" maxlength="32" value="{PASSWORD_CONFIRM}" />
</td>
</tr>
##
##----------[ AFTER, ADD ]-------------------------------
##
<!-- Visual Confirmation -->
<!-- BEGIN switch_confirm -->
<tr>
<td class="row1" colspan="2" align="center"><span class="gensmall">{L_CONFIRM_CODE_IMPAIRED}</span><br /><br />{CONFIRM_IMG}<br /><br /></td>
</tr>
<tr>
<td class="row1"><span class="gen">{L_CONFIRM_CODE}: * </span><br /><span class="gensmall">{L_CONFIRM_CODE_EXPLAIN}</span></td>
<td class="row2"><input type="text" class="post" style="width: 200px" name="confirm_code" size="6" maxlength="6" value="" /></td>
</tr>
<!-- END switch_confirm -->
|
Admin Panel Configuration - Blank Field
This compatibility issue affects any template in the Templates Database listed as compatible with phpBB 2.0.11 or later. You may find that after installing one of these templates on a forum using phpBB 2.0.0 - 2.0.10, there is a field in the Administration Control Panel > General > Configuration page that is missing a text label. This field, in phpBB 2.0.11 or later, is for enabling the built-in visual confirmation system. It has no use in previous phpBB versions unless the visual confirmation system has been installed.
To fix this issue, you can simply ignore the field, upgrade to phpBB 2.0.11, or install the visual confirmation system on your older phpBB version. There are instructions for installing the system in the contrib/ directory of the phpBB 2.0.7 - 2.0.10 downloads. _________________ Phantasy Star: The Fringes of Algo
Install, remove, or upgrade SQL with Advanced DB Update Generator! Now with phpBB 3 Support!
My phpBB Books, Hacks, and Other Works «·» 70+ Listings @ phpBBHacks.com |
|