I have these error messages in the forum error log:
8: Undefined offset: 532
File: /home/xxxxx/public_html/xxxxx/Sources/TPSubs.php
Line: 682
8: Undefined offset: 533
File: /home/xxxxx/public_html/xxxxx/Sources/TPSubs.php
Line: 683
'size' => array('code' => 'size', 'before' => '', 'after' => '', 'description' => $txt[532]),
'face' => array('code' => 'font', 'before' => '', 'after' => '', 'description' => $txt[533]),
-----------------------------
8: Uninitialized string offset: 0
File: /home/xxxxx/public_html/xxxxx/Themes/default/TPwireless.template.php
Line: 223
echo '<p class="titlebg">' . $context['linktree'][0]['name'] . '</p>';
-------------------------------
8: Undefined variable: avatar_height
File: /home/xxxxx/public_html/xxxxx/Sources/TPortal.php
Line: 643
8: Undefined variable: avatar_width
File: /home/xxxxx/public_html/xxxxx/Sources/TPortal.php
Line: 643
although this one points to that line the actual variables are in a line or two down further
can you please tell me what to do?
smf 1.1.3
tp 1.0 RC1.1
The first two errors 532/533 are SMF language strings. I think they are in Themes/default/languages/Post.english.php so please check that file and make sure they are there.
For avatar* errors:
Find in TPortal.php:
function doTPpage()
{
global $db_prefix, $tp_prefix, $context, $scripturl,$txt , $user_info, $settings , $modSettings, $ID_MEMBER, $boarddir, $boardurl, $sourcedir;
$tp_prefix = $settings['tp_prefix'];
Add After:
// setup the avatar code
if ($modSettings['avatar_action_too_large'] == 'option_html_resize' || $modSettings['avatar_action_too_large'] == 'option_js_resize')
{
$avatar_width = !empty($modSettings['avatar_max_width_external']) ? ' width="' . $modSettings['avatar_max_width_external'] . '"' : '';
$avatar_height = !empty($modSettings['avatar_max_height_external']) ? ' height="' . $modSettings['avatar_max_height_external'] . '"' : '';
}
else
{
$avatar_width = '';
$avatar_height = '';
}
For the undefined offset: 0 error, I cannot reproduce that error. Do you know how or on what page you are seeing this error? What URL on your site?
Thanks for the reply.
I did the code addition to the TPortal.php file and it seems to have stopped the error message cause no matter what I post or reply to the error is gone from admin/error log.
In the post.template.english file--smf doesn't list the font size and face with just one number anymore:
$txt['font_face'] = 'Font Face';
$txt['font_arial'] = 'Arial';
$txt['font_times'] = 'Times New Roman';
$txt['font_comic'] = 'Comic Sans MS';
$txt['font_verd'] = 'Verdana';
$txt['font_heatt'] = 'Haettenschweiler';
$txt['font_taho'] = 'Tahoma';
$txt['font_size'] = 'Font Size';
$txt['size_9'] = '9pt';
$txt['size_10'] = '10pt';
$txt['size_11'] = '11pt';
$txt['size_12'] = '12pt';
$txt['size_13'] = '13pt';
$txt['size_14'] = '14pt';
not sure but I think it makes for easier addition of those nifty dropdown menus,but I am not sure.
Should I make the reference in the code match the ones in red or the actual font - size listed in the coding?
Another thing, it would seem the errors are not there today with all the activity the members are doing at our attic...lol weird.
The font_face $txt string is from SMF2. SMF1 uses the $txt[553] format. So either you uploaded the wrong text files or replaced those strings some how. I'm not sure what you should do at this point. Do whatever works for you I guess.
aha, ok I will check a cuple of my mods that are installed to see which one changed it...that would be the only way. cause I have not a single SMF2 file uploaded...lol
will let you know
I checked the two mods for drop down menus concerning fonts the primary one that needs to be installed for the enhanced one to work is the culprit: FontAndSizeDropDown
it is the one that repalces the original code. Funny thing though is today no error messages at all just a notice of a spammer trying to lurk about...thank you.