UseBB Community

The official board for UseBB help and discussion

UseBB Community » Help & Support » Undefined variable: levelclass

Undefined variable: levelclass

Moderators: Gaia.

Page: 1

Author Post
Member
Registered: Jan 2007
Posts: 12
Hi everybody,

sorry, but my english isnt well, but i try it.

i instal the boardsoftware on www.gruenderlexikon.de/forum

before there was phpbb installed.
the serversystem:
Linux-Distribution debian 3.1

PHP Version 4.4.2
mysql

usebb version 1.4 the latest one.
i used the Convertors to convert the posts from phpbb to usebb, which works by www.betriebsausgabe.de/forum exactly.

this site run on the same server linke the other one.
back to gruenderlexikon.de:
after the upload and the converter produce the software the following error:

"

In file functions.php on line 2015:

E_NOTICE - Undefined variable: levelclass
"
you can see it on www.gruenderlexikon.de/forum

what can i do, to handle this errormessage?
the dates from phpbb are correctly write in the database and i dont understand the parameter "levelclass" in the function.php

i try to switsch off the error messages of php with error_reporting(E_ALL);
no way :roll:

i dont understand why the board on www.betriebsausgabe.de/forum with on the same server like www.gruenderlexikon.de/forum runs and gruenderlexikon.de dont work.

thanks for your help

torsten
Developer
Registered: Apr 2004
Posts: 2215
Location: Belgium
What does the following query on the members table say?
SELECT DISTINCT(level) FROM usebb_members ORDER BY level

It should only return at most 3 rows (since there are only three levels in UseBB, member (1), moderator (2) and admin (3)).
Your phpBB forum probably had more levels, so the converion of these level values didn't run really smooth. If you can locate a level above 3, you could easily fix it using a small SQL query.
_______________
--Dietrich (developer)
UseBB roadmap, dev mailing list & weblog
Member
Registered: Jan 2007
Posts: 12
Hi Dietrich,

sorry for posting in the wrong forum.
But im very happy because:
1. i can write in english and my studi on the university isnt for less
2. i have less expiriences in php, but i got it and i have the solution for the problem

case 0:
$levelclass = '';
break;

the board works now

thanks
can you speak german? i think ist couriose, when we talk english and anyone can speak german.

what ever

thanks to you
Developer
Registered: Apr 2004
Posts: 2215
Location: Belgium
A member record with level 0 is useless within UseBB. 0 is used as the level for guests. So, if this record isn't really a member (phpBB has a record for guests but it has user ID -1 and is normally filtered by the convertor) the solution is to just remove the member's record.

As for German, I speak very less German; besides, this is an English only forum. :)
_______________
--Dietrich (developer)
UseBB roadmap, dev mailing list & weblog
Member
Registered: Oct 2006
Posts: 4
Location: Germany
@Torsten

to switch off php errors you have to use error_reporting(0);
error_reporting(E_ALL); displays all errors

on some hosts you also have to set ini_set('display_errors', TRUE);
_______________
code is poetry
Developer
Registered: Apr 2004
Posts: 2215
Location: Belgium
Disabling errors for UseBB will be hard to do, since it uses a custom error handler which sets the error level to E_ALL and which quits the script (die(...)) on each error or notice.

In 2.0 this will most likely change so errors are logged somewhere easily accessible and only shown to the user when requested.
_______________
--Dietrich (developer)
UseBB roadmap, dev mailing list & weblog

Page: 1

UseBB Community » Help & Support » Undefined variable: levelclass

UseBB Community is powered by UseBB 1 Forum Software