Welcome to Geeklog Tuesday, May 21 2019 @ 10:38 pm EDT

Geeklog Forums

Bad-Behavior 2.2.16 Blank Screen


Status: offline

gtgillis

Forum User
Full Member
Registered: 05/11/03
Posts: 121
Location:Spring, TX
I administer three different sites all running GL 2.1.0. When I installed Bad-Behavior 2.2.16 on the first one all worked as expected. When I tried installing it on the other two sites I get a blank screen as soon as I add the line to Bad-Behavior lib-common.php.

Any ideas?

matrox66

Anonymous
I have the same Probleme, i think there are some Problems with the Directorys.

Status: offline

Laugh

Site Admin
Admin
Registered: 27/09/05
Posts: 1349
Weird....

Is there anything in the error log? If not it sounds like you are being blocked by the BB plugin.
One of the Geeklog Core Developers.

Status: offline

gtgillis

Forum User
Full Member
Registered: 05/11/03
Posts: 121
Location:Spring, TX
There is nothing in the error.log

I tracked it down to the bb2_install function in bad-behavior-geeklog.php. The function checks to see if bb2_installed with a value of 1 is in the gl_vars table. If not it calls bb2_db_query to presumably create the gl_bad_behavior2 table then insert bb2_installed with a value of 1 in gl_vars. The only problem is that there is no function named bb2_table_structure in the install package so it hangs. It looks like this function used to be in core.inc.php but it not in 2.2.16

If I manually create the gl_bad_behavior2 table and insert bb2_installed in the vars table it appears to run fine.I am letting it run now to see if it catches anything.

PHP Formatted Code

function bb2_install() {
    $settings = bb2_read_settings();
    if( $settings['is_installed'] == false ) {
            bb2_db_query(bb2_table_structure($settings['log_table']));
            $settings['is_installed'] = true;
            bb2_write_settings( $settings );
    }
}
 

Status: offline

remy

Forum User
Full Member
Registered: 09/06/03
Posts: 148
Location:Rotterdam & Bonn
The function bb2_table_structure moved to bad-behavior-mysql.php. This file is missing (and not included) in the bb2 plugin.

As long as you are upgrading, you're fine, since the table did not change, though there is a second function that creates log file entries (and probably missing too?):
PHP Formatted Code

note: cannot show the code since a server error pops up persistently
function bb2_table_structure($name)
// Insert a new record
function bb2_insert($settings, $package, $key)
 

Status: offline

gtgillis

Forum User
Full Member
Registered: 05/11/03
Posts: 121
Location:Spring, TX
I am getting log entries on both sites where I manually created the table so everything appears to work now.

Function bb2_insert is located in bad-behavior-geeklog.php.

Status: offline

Laugh

Site Admin
Admin
Registered: 27/09/05
Posts: 1349
If someone has the time can we get it fixed and repackaged and uploaded to Geeklog.net. Once that is done I will remove the other version.

Tom
One of the Geeklog Core Developers.

All times are EDT. The time is now 10:38 pm.

  • Normal Topic
  • Sticky Topic
  • Locked Topic
  • New Post
  • Sticky Topic W/ New Post
  • Locked Topic W/ New Post
  •  View Anonymous Posts
  •  Able to post
  •  Filtered HTML Allowed
  •  Censored Content