[Fixed]: Vbulletin 4.0 with cpg 1.4.25 [Fixed]: Vbulletin 4.0 with cpg 1.4.25
 

News:

CPG Release 1.6.26
Correct PHP8.2 issues with user and language managers.
Additional fixes for PHP 8.2
Correct PHP8 error with SMF 2.0 bridge.
Correct IPTC supplimental category parsing.
Download and info HERE

Main Menu

[Fixed]: Vbulletin 4.0 with cpg 1.4.25

Started by alfisti.net, December 24, 2009, 01:43:07 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

alfisti.net

Hi,

I testet the bridge today with:
4.0 "Gold" (upgraded from 3.8)
Coppermine 1.4.25 (brand new installation / using bridge manager)

It work fine :)
Usergroups, usernames and I guess also all right-settings (I have checked only two, but I am sure that all other will also work).

I only have some problems with the collation / character encoding but I guess this is a problem from the database collation (UTF8 works fine for the gallery phrases, Western-ISO 8859-1 works fine for the usernames with german characters).

Happy x-mas
André

Joachim Müller


alfisti.net

Hi Joachim,

I want to learn what I made wrong :) I don't understand your link.
This is just for information that the bridge works fine because I found nothing about vB 4.0 in the forum (and vB3 is only named in the Bridge Manager).
I can't post a link because my installation is only a non-public testversion (licence agreements of vB: use only 1 installation with public access).

I wrote the note for collation incompatiblity because it happened to my test. But I' am sure that this is a problem of my installation and not a problem of the bridge :)

Regards
André

phill104

The link Joachim posted is requesting that you post a link to your gallery. This is mandatory as per the board rules. It is very hard to look into a problem if we cannot see it.
It is a mistake to think you can solve any major problems just with potatoes.

alfisti.net

The bridge will not work anymore with vB 4.01 :(

I have had problems with the cookie salt in a older version after an update.
vBulletin changed the value of the cookie_salt from the licence number to a random number which comes with the download.
The value is written in the file /includes/function.php of vB
define('COOKIE_SALT', 'ZUShshsgdhTZTUJS');
The value is only a sample.

I found nothing special in the documentation how the bridge is working exactly.
Is it possible that this is the reason why it don't work anymore?

Thanks


Joachim Müller

Ignoring our request to post a link to your gallery will result in your subsequent postings getting ignored.

codjo

Here is a link to my gallery with the same problem: http://www.mishki.de/Forum/content.php?6-Galerie

I have also vbulletin 4.0.1 installed and after this I can not connect anymore to the coppermine gallery.
After typing the link to the gallery I see login and when I click this I come to the starting page of my forum.

greetings
Jochen

codjo

Username and password for checking is possible to give you but I don´t want to post this here in this public area, maybe I can send it somehow (E-Mail or equal) without need of posting it here.

alfisti.net

make a test account with no further rights. The support don't need a admin account!
Only a standard user... So that Joachim can see what happens with the cookies.
And after Joachim tested this, you can delete this user.

@Joachim
As I wrote you in the thread, I have no public version, only a testversion.
I ask for a hint to find the problem, I don't asked for a solution ;)

And my first post was only posted to let you know that vB 4.0 will work fine with the bridge, I don't asked for support.



codjo

Ok, here is the link again and the User and Password:

Coppermine install: http://www.mishki.de/cpg1410/
Forum install: http://www.mishki.de/Forum/
Coppermine version: cpg1.4.25
Forum version: Vbulletin 4.0.1
Test user account: Testuser / test123



codjo

It is working now, I found the solution in the vbulletin board: http://www.vbulletin.com/forum/project.php?issueid=35386

The problem is, that vbulletin have changed the cookie prefix from bb to bb_

$config['Misc']['cookieprefix'] = 'bb_';

After this change, it is working.

Joachim Müller

Thanks for your report. However, the fix might do the job, but is not right as far as application design is concerned. I have posted this on the vB forum:
Quote from: http://www.vbulletin.com/forum/project.php?issueid=35386At vB devs:
Your proposed fix is to populate a third-party file (coppermine's include/config.inc.php, seen from your perspective, is a third party file) with a variable from your app? And that is supposed to be a true, genuine fix?
I'm not a vBulletin expert, but as far as I can see you store your settings inside the $config array, which is available for processing for third party apps (that's what the coppermine bridge for vbulletin does): we use PHP's require_once command to include vB's file includes/config.php. The corresponding code in bridge/vbulletin30.inc.php is            $this->boardurl $BRIDGE['full_forum_url'];
            require_once(
$BRIDGE['relative_path_to_config_file'] . 'includes/config.php');
            
$this->use_post_based_groups $BRIDGE['use_post_based_groups'];

This is meant to give us access to all of your settings inside the $config-array, as we later use          // Running on vBulletin 3.5.x
            
$this->db = array(
                
'name' => $config['Database']['dbname'],
                
'host' => $config['MasterServer']['servername'] ? $config['MasterServer']['servername'] : 'localhost',
                
'user' => $config['MasterServer']['username'],
                
'password' => $config['MasterServer']['password'],
                
'prefix' => $config['Database']['tableprefix']
            );

Due to vB not being FOSS I don't have a copy of vB to test this, so I can't tell for sure. But judging from the fact that manually populating $config['Misc']['cookieprefix'] = 'bb_'; in a coppermine file fixes the issue for the posters here means that the scope of that variable is wrong in your application or that it get's populated at a later stage. The expected reply from vB staff would have been "we don't support third-party applications like Coppermine", which is at least what we tell users who ask questions about vBulleting on our forum. Blaming Coppermine to be at fault sounds lame to me though: upgrading your app broke the bridge, and it turns out that it happens because of something the vB devs changed in vBulletin (changing the cookie prefix from "bb" to "bb_").
We (the Coppermine developers) are not fond of a proposed "fix" that requires editing a coppermine component that is not related at all. If you must edit a coppermine file, edit bridge/vbulletin30.inc.php and add your proposed change there. Even better would be not to require end user to edit that file at all by modifying coppermine's bridge file with a little if/then toggle:if (vB-Version >= 4) {
   $config['Misc']['cookieprefix'] = 'bb_';
}
would do the trick - we just need to figure out where the version number of vB is kept (in which variable or constant that is available for the third-party page). So my question at the vB devs is: is there a varibale that we could use, or do you have another proposal.

Joachim Müller (aka GauGau)
- Coppermine project manager -
I have moved your thread to the testing/bugs board, although this is not a genuine coppermine "bug".

Nibbler

The proposed change is to vb's own config.php.

Nibbler

My suggestion would be to drop the auto-detection of the cookie prefix and instead prompt the admin for it in the bridge manager like some other bridges do.

BAJR

I am sorry to say that the bb_  fix that I thought had worked - failed..  so who knows why it worked briefly.

I am a bit annoyed at Vbulletin as they have been quite offhand about 'whose problem is it'

At the end of the day...  Coppermine is the best gallery solution....   Vbulletin 4.0 is a great mix of CMS and Forum

as it stands I jsut can't join them.. will anybody be looking at creating a VB4  bridge.   ?




codjo

Maybe this will help to solve our problem, this work for me now since some time and it seems that this is the solution.

In the file cpgxxxx/bridge/vbulletin.30.inc.php you need to change the following:


[i]Search for:[/i]

if (isset($_COOKIE[$this->cookie_name . 'sessionhash'])) {

[i]and change it to:[/i]

if (isset($_COOKIE[$this->cookie_name . '[b]_[/b]sessionhash'])) {

[i]Then go one line down or search for: [/i]

$session_id = addslashes($_COOKIE[$this->cookie_name . 'sessionhash']);

[i]and change it to:[/i]

$session_id = addslashes($_COOKIE[$this->cookie_name . '[b]_[/b]sessionhash']);



Hope this helps finally!

Best regards

Jochen (aka Mishki)
(www.mishki.de)

codjo

Maybe this will help to solve our problem, this work for me now since some time and it seems that this is the solution.

In the file cpgxxxx/bridge/vbulletin.30.inc.php you need to change the following:

Can somebody remove my previous post, I can not edit it and just saw that bold and italic not work inside of code Tag.


Search for:

if (isset($_COOKIE[$this->cookie_name . 'sessionhash'])) {

and change it to:

if (isset($_COOKIE[$this->cookie_name . '_sessionhash'])) {

Then go one line down or search for:

$session_id = addslashes($_COOKIE[$this->cookie_name . 'sessionhash']);

and change it to:

$session_id = addslashes($_COOKIE[$this->cookie_name . '_sessionhash']);



Hope this helps finally!

Best regards

Jochen (aka Mishki)
(www.mishki.de)

Paul M

Quote from: codjo on January 25, 2010, 12:11:22 AM
Maybe this will help to solve our problem, this work for me now since some time and it seems that this is the solution.

In the file cpgxxxx/bridge/vbulletin.30.inc.php you need to change the following:

Can somebody remove my previous post, I can not edit it and just saw that bold and italic not work inside of code Tag.


Search for:

if (isset($_COOKIE[$this->cookie_name . 'sessionhash'])) {

and change it to:

if (isset($_COOKIE[$this->cookie_name . '_sessionhash'])) {

Then go one line down or search for:

$session_id = addslashes($_COOKIE[$this->cookie_name . 'sessionhash']);

and change it to:

$session_id = addslashes($_COOKIE[$this->cookie_name . '_sessionhash']);



Hope this helps finally!

Best regards

Jochen (aka Mishki)
(www.mishki.de)

That is the correct way to fix it.

In vB 4.0.1, all the session cookie names have changed, so sessionhash is now _sessionhash

Joachim Müller

Quote from: codjo on January 25, 2010, 12:11:22 AM
Can somebody remove my previous post, I can not edit it and just saw that bold and italic not work inside of code Tag.
Actually, the instructions should look like this as far as correct bbcode is concerned:

Edit cpgxxxx/bridge/vbulletin.30.inc.php
Search for:
if (isset($_COOKIE[$this->cookie_name . 'sessionhash'])) {and change it to:if (isset($_COOKIE[$this->cookie_name . '_sessionhash'])) {

Then go one line down or search for:$session_id = addslashes($_COOKIE[$this->cookie_name . 'sessionhash']);and change it to:$session_id = addslashes($_COOKIE[$this->cookie_name . '_sessionhash']);

BAJR

I am and ever will be in your debt..  and thank you so much for this help.   If only other groups were as helpful and precise as yourselves.