TP-Docs
HTML5 Icon HTML5 Icon HTML5 Icon
TP on Social Media

Recent

Welcome to TinyPortal. Please login or sign up.

May 19, 2024, 12:04:50 AM

Login with username, password and session length
Members
  • Total Members: 3,886
  • Latest: Grendor
Stats
  • Total Posts: 195,189
  • Total Topics: 21,220
  • Online today: 70
  • Online ever: 3,540 (September 03, 2022, 01:38:54 AM)
Users Online
  • Users: 0
  • Guests: 74
  • Total: 74

[bugtracker] Undefined variable error for avatar_height & avatar_width

Started by gouri, April 04, 2010, 05:35:06 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

gouri

I Have encountered the error after the updation of the forum from SMF 1.1.11 to SMF 2.0 RC3 and then Installed the TP 1.0 Beta 5

In Tinyportal tab frontpage I selected the option  "Forum-posts and articles - sorted on date"

Then I am getting the errors filled in error log

QuoteGuest
66.249.71.229   
Type of error: Undefined
http://tweak2.com/index.php?
8: Undefined variable: avatar_height
File: /home/******/public_html/Sources/TPortal.php
Line: 1659

Guest
66.249.71.229   
Type of error: Undefined
http://tweak2.com/index.php?
8: Undefined variable: avatar_width
File: /home/*****/public_html/Sources/TPortal.php
Line: 1659

So I opened the TPortal.php from Sources folder and navigated to the articles

Quoteelseif(in_array($context['TPortal']['front_type'], array('forum_articles', 'forum_selected_articles')))

And added observed that all other if conditions defined avatar_height and avatar_width depending on some condtion but this one doesn't

So added the blank variables to the starting of the above quoted elseif condition. And this solved the problem.

Quote$avatar_height='';
$avatar_width='';

Here is the forum topic discussed on this http://www.tinyportal.net/index.php?topic=32240.0