Forums

Strange problem with plugin (2 posts)

  1. jdp
    Member
    Posted 4 years ago #

    I'm trying to get a vBulletin username to display in the wordpress header.

    vBulletin is running on the site root and WP in a subdirectory. I need to include vB's global.php to get the username.

    The top of the plugin script has the following lines:

    $vwd = '/usr/******/docs';
    $cwd = getcwd();
    chdir($vwd);
    if (!file_exists($vwd . '/global.php'))  { echo "cannot include $vwd/global.php.  You should check your path!"; exit; }
    require_once($vwd . '/global.php');
    chdir($cwd);

    However, when trying to activate the plugin, I get a fatal error and the plugin stays de-activated. If I comment out the "require_once" line, it activates fine. If I then uncomment it and re-upload the plugin script, everything works fine EXCEPT if I try to edit settings of other plugins I have installed (then I get a message "Cannot load 0").

    Any idea what's causing this strange behaviour? Or any idea how I can better integrate the vB username into my WP templates?

    Many thanks!

  2. jamiefehr
    Member
    Posted 3 years ago #

    I'm working on it. There's something really strange about how recent versions of wordpress interact with vbulletin.

Topic Closed

This topic has been closed to new replies.

About this Topic

Tags