coppermine-gallery.com/forum

Support => Older/other versions => cpg1.2 Standalone Support => Topic started by: Percherie on May 19, 2004, 07:43:08 PM

Title: Coppermine - YabbSE
Post by: Percherie on May 19, 2004, 07:43:08 PM
Hello with all,


I use YabbSE 1.5.5 and I have just installed Coppermine 1.2.1 but I do not manage to use the following file: "/bridge/yabbse.inc.php"

I have it editer to indicate where this finds the file Setting.php de YabbSE but I have a return error:


Notice: Undefined variable: CONFIG in c:\program files\easyphp\www\yabbse\gallerie\bridge\yabbse.inc.php on line 365
Coppermine critical error:
Unable to connect to YaBB SE Board database !

MySQL said: Unknown MySQL Server Host 'YS_BD_HOST' (11001)




What is necessary it to make??
Title: Re: Coppermine - YabbSE
Post by: Casper on May 19, 2004, 08:41:03 PM
It is telling you it can't find the database server for the forum.  Have you edited these lines of the bridge file;
// database configuration
define('YS_DB_NAME', $db_name); // The name of the database used by the board
define('YS_DB_HOST', $db_server); // The name of the database server
define('YS_DB_USERNAME', $db_user); // The username to use to connect to the database
define('YS_DB_PASSWORD', $db_passwd); // The password to use to connect to the database


So if your database is on 'localhost' your database is called 'forum' and your database password is 'yeeha', this code should look like this;
// database configuration
define('YS_DB_NAME', 'forum'); // The name of the database used by the board
define('YS_DB_HOST', 'localhost'); // The name of the database server
define('YS_DB_USERNAME', 'your-username'); // The username to use to connect to the database
define('YS_DB_PASSWORD', 'yeeha'); // The password to use to connect to the database


This all assumns you are using version 1.2.1.
Title: Re: Coppermine - YabbSE
Post by: Percherie on May 19, 2004, 09:18:23 PM
I already tested but that does not function I have even verifier with the following order:

echo YS_DB_HOST; and that functions


I think that that from the line 365 but I come not to know not the PHP very well

define(' UDB_CAN_JOIN_TABLES', (YS_DB_HOST == $$CONFIG['dbserver'>] && (YS_DB_NAME == $$CONFIG['dbname'>] || YS_DB_USERNAME == $$CONFIG['dbuser'>])));
Title: Re: Coppermine - YabbSE
Post by: Casper on May 19, 2004, 11:12:39 PM
Please post what your lines, as I put above, but with ***** instead of the password.
Title: Re: Coppermine - YabbSE
Post by: jack on May 20, 2004, 12:37:15 AM
With the YaBB SE bridge, you MUST have the coppermine and YaBB SE data in the same database. Just fixing that typo won't help matters much.

STOP PRESS : I have today got the SMF bridge with the SMF data in a different database from Coppermine. To backport this into the YaBB SE bridge, however, is not that trivial. I'll hopefully have it working for the release of 1.3.
Title: Re: Coppermine - YabbSE
Post by: Percherie on May 20, 2004, 08:38:36 AM
The last code

define('YS_DB_NAME', $db_name); // The name of the database used by the board
define('YS_DB_HOST', $db_server); // The name of the database server
define('YS_DB_USERNAME', $db_user); // The username to use to connect to the database
define('YS_DB_PASSWORD', $db_passwd); // The password to use to connect to the database

// The web path to your YaBB SE Board directory
// In this example http://yoursite_name.com/yabbse/
define('YS_WEB_PATH', 'http://perch/yabbse/');
// The Name of the Cookie used for YaBBSE logon
define('YS_COOKIE_NAME', $cookiename);
// Prefix for the database tables
define('YS_TABLE_PREFIX', $db_prefix); // Table Prefix


And my news code

define('YS_DB_NAME', 'yabbse'); // The name of the database used by the board
define('YS_DB_HOST', 'localhost'); // The name of the database server
define('YS_DB_USERNAME', 'root'); // The username to use to connect to the database
define('YS_DB_PASSWORD', ''); // The password to use to connect to the database

// The web path to your YaBB SE Board directory
// In this example http://yoursite_name.com/yabbse/
define('YS_WEB_PATH', "$boardurl/");
// The Name of the Cookie used for YaBBSE logon
define('YS_COOKIE_NAME', 'YaBBSE155');
// Prefix for the database tables
define('YS_TABLE_PREFIX', 'yabbse_'); // Table Prefix


Then the part of the code which poses problem is as follows but I do not see what it is necessary to do to correct or make function this script

// ------------------------------------------------------------------------- //
// Define wheter we can join tables or not in SQL queries (same host & same db or user)
define('UDB_CAN_JOIN_TABLES', (YS_DB_HOST == $CONFIG['dbserver'] && (YS_DB_NAME == $CONFIG['dbname'] || YS_DB_USERNAME == $CONFIG['dbuser'])));
// Connect to YaBB SE Database if necessary
$UDB_DB_LINK_ID = 0;
$UDB_DB_NAME_PREFIX = YS_DB_NAME ? '`' . YS_DB_NAME . '`.' : '';
if (!UDB_CAN_JOIN_TABLES) {
    $UDB_DB_LINK_ID = @mysql_connect(YS_BD_HOST, YS_DB_USERNAME, YS_DB_PASSWORD);
    if (!$UDB_DB_LINK_ID) die("<b>Coppermine critical error</b>:<br />Unable to connect to YaBB SE Board database !<br /><br />MySQL said: <b>" . mysql_error() . "</b>");
}
Title: Re: Coppermine - YabbSE
Post by: Percherie on May 20, 2004, 08:59:38 AM
I succeeded in correcting all the errors, for the following message:

Notice: Undefined variable: CONFIG in c:\program files\easyphp\www\yabbse\gallerie\bridge\yabbse.inc.php on line 365

I have to add at the beginning of script

require_once("../include/config.inc.php");

But I do not know if this modification is correct.
Now it this master key nothing whole on the basis of data and the album photo takes into account the members of yabbse, which is necessary it to make? where is it necessary to put the file yabbse.inc.php??

Personally I do not speak English (lives the translators) and I have one can of evil seek information on the site
Title: Re: Coppermine - YabbSE
Post by: jack on May 20, 2004, 03:40:26 PM
I mis-read what Casper was saying earlier. You DO NOT need to modify any lines in the YaBB SE bridge, other than the

require_once("../yabbse/Settings.php");

First, replace the bridge file with an un-touched copy from the zip file you downloaded.

Change this to point to your YaBB SE settings file. Some people have reported that
they need to set it to the full path of where it is, so something similar to :-

require_once("c:\program files\easyphp\www\yabbse\Settings.php");

is probably right for you.

As I said before, this bridge DOES NOT work unless the coppermine data is in the same database as the YaBB SE data.
Title: Re: Coppermine - YabbSE
Post by: Casper on May 20, 2004, 05:26:56 PM
Sorry,

I knew this was the case with version 1.3, but was under the impression 1.2.1 still needed modifying.
Title: Re: Coppermine - YabbSE
Post by: jack on May 20, 2004, 05:33:24 PM
No Worries,

I should have realised when I saw you telling him to change the line :-

define('YS_DB_HOST', $db_server);

But for some reason my brain could not have been plugged in then ::)
Title: Re: Coppermine - YabbSE
Post by: JSermarini on August 01, 2004, 06:07:18 AM
With the bridge program installed, how can I give one of the Yabb SE usergroups admin access in coppermine?
Title: Re: Coppermine - YabbSE
Post by: Joachim Müller on August 01, 2004, 08:15:23 AM
By making them yabbse admins. Recommendation: don't! If you don't want them to be yabbse admins, why should you want them to be coppermine admins?

GauGau