#1836 bug in Convert.php

Tom Diesel

I was trying to convert my categories from 0.10 and always ended up at the error message: "Fatal error: Call to a member function on a non-object". After much sweat and several days! of wading through all related websites and the phpws source code, I found the problem in Convert.php.

In the function getSourceDB() the database is loaded. When the module to convert checks the already converted tables first (isConverted()) and the database is the same and you use a table prefix then the function loadDB tries to load the -to be converted from- table with the PHPWS_TABLE_PREFIX instead of the $_SESSION['Convert_Tbl_Prefix']!

To fix that change in file convert/class/Convert.php in the function getSourceDB() the following line (119 in version 5830):

PHPWS_DB::loadDB($dsn, $prefix);


PHPWS_DB::loadDB($dsn, $prefix, "TRUE");

Php Version: 4.4.7
Web Server: Apache 1.3
Operating System: Linux
SQL Server: MySQL 3.23.58
Browser: IBrowse 2.4
PhpWebSite Version: 1.5.2


  • Anonymous - 2008-07-18
    • assigned_to: nobody --> stardog
    • status: open --> open-accepted
  • Anonymous - 2008-07-28
    • status: open-accepted --> closed-fixed
  • Anonymous - 2008-07-28

    Logged In: YES
    Originator: NO

    Thanks for doing the leg work. Fixed in subversion.


Log in to post a comment.