coppermine-gallery.com/forum

Support => Older/other versions => cpg1.3.x Support => Topic started by: erroneus on July 17, 2004, 01:08:05 PM

Title: [Invalid]: Possible bug?
Post by: erroneus on July 17, 2004, 01:08:05 PM
Ever since I uploaded some pictures to some of my albums, I notice that when I logout of coppermine, the following appears on the very top of the page:

Notice: unserialize(): Error at offset 0 of 7 bytes in /usr/home/sites/www.lmtchatonline.com/web/gallery/bridge/phpbb.inc.php on line 90

I even upgraded to 1.3.1, same thing  happens. It goes way if I log back in.
Title: Re: Possible bug?
Post by: Joachim Müller on July 17, 2004, 01:14:11 PM
test account (non-admin) for http://www.lmtchatonline.com/gallery/ please...
Post your version of coppermine as well.

GauGau
Title: Re: Possible bug?
Post by: erroneus on July 18, 2004, 12:45:48 AM
login: lunatic
pass: blah123

Running 1.3.1

Thanks.
Title: Re: Possible bug?
Post by: kegobeer on July 18, 2004, 01:44:10 AM
Your error shows an issue in the phpbb bridge.  However, the link to your forum is incorrect (http://www.lmtchatonline.com/gallery/www.lmtchatonline.com/phpbb).  Maybe an issue with your integration with phpbb.  Various other links are also incorrect (example: http://www.lmtchatonline.com/gallery/www.lmtchatonline.com/gallery).

I logged into your site with your test user, and didn't see any errors while I was there.
Title: Re: Possible bug?
Post by: erroneus on July 18, 2004, 02:12:58 AM
Yeah it was just those two links that were incorrect. Fixed now. Thanks.  ;D
I've never had problems with my phpBB integration. This error started appearing when I uploaded a lot of pics to one of my albums.

This is my line 90 in the phpBB bridge file:
$sessiondata = unserialize($HTTP_COOKIE_VARS[PHPBB_COOKIE_PREFIX . '_data']);

I had the same problem before I upgraded to 1.3.1.
Title: Re: Possible bug?
Post by: Joachim Müller on July 18, 2004, 08:22:19 AM
I confirm kegobeer's report: no error for me when looging out.
But, looking at your source code, I noticed something fishy in the theme you're using. Did you make sure to have applied the changes mentioned in docs/theme.htm when upgrading from cpg1.2.x to cpg1.3.x?

GauGau
Title: Re: Possible bug?
Post by: erroneus on July 19, 2004, 04:26:09 AM
it says for applying changes to custom themes from 1.2.x to 1.3.x. I originally had 1.3.0 and upgraded to 1.3.1. So that wouldn't be the issue. I still read over it to verify that the changes were made though.

Why is it that when I click on Memberlist while logged in as a regular user it'll direct me to:
http://www.lmtchatonline.com/phpBB/admin/index.php? It of course says I don't have access to make administration changes. But when I'm logged in as an admin is simply directs me to /phpBB.
Title: Re: Possible bug?
Post by: kegobeer on July 19, 2004, 06:19:59 AM
For the memberlist problem...

Either some variable isn't getting set, or the link the phpbb bridge file sets isn't right.  I don't use phpBB, so I can't verify if this will fix it, but open up /bridge/phpbb.inc, and change

function udb_edit_users()
{
    $target = 'admin/index.php';
    udb_redirect($target);
}


to
function udb_edit_users()
{
    $target = 'memberlist.php';
    udb_redirect($target);
}


For the original problem...

If you switch to the default Coppermine theme, do you still have the unserialize error?
Title: Re: Possible bug?
Post by: Joachim Müller on July 19, 2004, 07:14:44 AM
This is a known issue: you can't use the memberlist when using a bridged coppermine. Disable displaying the memberlist in coppermine config.

GauGau
Title: Re: Possible bug?
Post by: kegobeer on July 19, 2004, 07:40:35 AM
The memberlist works fine with the SMF bridge, although I didn't know until today as I leave the memberlist option switched off in Coppermine's admin.
Title: Re: Possible bug?
Post by: erroneus on July 19, 2004, 08:28:03 AM
I changed the theme to classic, and am still getting the same error message on top when I logout (it goes away when I log back in). I tried the lunatic reg. user account i posted before, and the same thing happens as when I logout of my admin account.

I think I found another bug. When I click on the Show/hide info button when browsing a picture, then click on my name (indicating that I uploaded that pic), it shows my profile. But on my profile picture it seems to be showing the latest pic that I uploaded. Same problem is happening to another admin.
Title: Re: Possible bug?
Post by: erroneus on July 19, 2004, 08:33:10 AM
OK it appears this problem is only happening on my computer. Maybe a browser issue..something messed up with my cookies? I  can logout with no errors on my roommate's computer. Thanks guys.
Title: Re: Possible bug?
Post by: Casper on July 19, 2004, 11:25:08 AM
Quote from: erroneus on July 19, 2004, 08:28:03 AM
I think I found another bug. When I click on the Show/hide info button when browsing a picture, then click on my name (indicating that I uploaded that pic), it shows my profile. But on my profile picture it seems to be showing the latest pic that I uploaded. Same problem is happening to another admin.

This is not a bug, it is expected behaviour.  There will be 1 or 2 pics in your profile (coppermine, not BB) depending on if you have uploaded pics and posted comments.  The left one is the last uploaded, and if clicked on, links to a meta album containing all pics you have uploaded.
The right one goes to all pics you have commented on.

Note, these profile meta albums respect permissions, so they do not show pics the viewer is not allowed to see.
Title: Re: Possible bug?
Post by: erroneus on July 19, 2004, 12:22:50 PM
Oh so when a visitor clicks on my profile they wont see the pic I last uploaded? I don't want someone to see it and think I'm a girl or something if the pic I last uploaded was a girl's pic, you know? Since the picture is simply displayed and no text around it describing what it is. It'll automatically  make people assume  that it's a picture of me.
Title: Re: Possible bug?
Post by: Casper on July 19, 2004, 12:47:51 PM
It will always be the last uploaded pic.

There is a mod somewhere to add the text 'last uploaded pic', and that has been incorporated into the next version.
Title: Re: Possible bug?
Post by: Joachim Müller on July 19, 2004, 12:49:11 PM
to make it clear to users that the pic shows the last uploaded or last commented pic, not an avatar of you, edit profile.php and find               $lastcom = '<td width="50%" valign="top" align="center">'
                            . '<a href="thumbnails.php?album=lastcomby&uid=' . $uid . '">'
                            . $lastcom
                            . '</a><br />';

Replace it with                $lastcom = '<td width="50%" valign="top" align="center">'
                            . '<a href="thumbnails.php?album=lastcomby&uid=' . $uid . '">'
                            . '<span class="thumb_title">Last comment by ' . $user_data['user_name'] . '<br /></span>'
                            . $lastcom
                            . '</a><br />';

Then, find                $user_thumb = '<td width="50%" valign="top" align="center">'
                            . '<a href="thumbnails.php?album=lastupby&uid=' . $uid . '">'
                            . $user_thumb
                            . '</a></td>';
and replace with                $user_thumb = '<td width="50%" valign="top" align="center">'
                            . '<a href="thumbnails.php?album=lastupby&uid=' . $uid . '">'
                            . '<span class="thumb_title">Last uploaded file by ' . $user_data['user_name'] . '<br /></span>'
                            . $user_thumb
                            . '</a></td>';


This should do the trick (the code I posted will be part of cpg1.4.0 which is still under development).

GauGau
Title: Re: Possible bug?
Post by: erroneus on July 19, 2004, 04:28:32 PM
Nice thanks.  ;D
Title: Re: Possible bug?
Post by: bxs122 on July 23, 2004, 12:57:59 PM
Quote from: erroneus on July 19, 2004, 08:33:10 AM
OK it appears this problem is only happening on my computer. Maybe a browser issue..something messed up with my cookies? I  can logout with no errors on my roommate's computer. Thanks guys.


I am having the same exact issue -- on my computer I don't get the problem but on other users computers they started seeing the problem after we start to upload images.
Any find on this one??
Title: Re: [Possibly unsolved]: Possible bug?
Post by: erroneus on July 24, 2004, 02:24:25 AM
Case re-opened. I'm still having the same problem with my computer, haven't yet figured out what it could be!
Title: Re: [Possibly unsolved]: Possible bug?
Post by: Streamer on January 06, 2005, 12:19:35 PM
Is this problem solved now? ???

I tried to fiind out solution to same kind of problem with no success. I have bridged phpbb 2.0.11 with cpg, and this problem came out when updating cpg 1.2 to 1.3.2. Phpbb 2.0.11 worked fine with cpg 1.2.

When I log in to cpg it redirects fine to gallery and shows that im logged in, but when I then click some link it kicks me out and shows error

"Notice: unserialize(): Error at offset 0 of 92 bytes in /home/customers/perho/public_html/kuvagalleria/bridge/phpbb.inc.php on line 90"

at the top of the page.

My gallery is at [removed]
My board at [removed]

you can test it with
login: test
passwd: test

(Board is in Finnish, so login=Käyttäjätunnus and passwd=Salasana :) )

I got the problem with Firefox 1, Opera 7.51, and IE 6 sp2

Versioncheck saved as html:
[removed]

Thanks a lot!
Title: Re: [Possibly unsolved]: Possible bug?
Post by: Joachim Müller on January 07, 2005, 10:30:17 AM
Make sure you run at least php4.3.10 and the most recent version of the zend optimizer, as there is a security flaw in PHP related to the serialization commands. Search the board for "Santy", or google for it.

Joachim
Title: Re: [Possibly unsolved]: Possible bug?
Post by: Streamer on January 07, 2005, 11:35:27 AM
Quote from: GauGau on January 07, 2005, 10:30:17 AM
Make sure you run at least php4.3.10 and the most recent version of the zend optimizer, as there is a security flaw in PHP related to the serialization commands. Search the board for "Santy", or google for it.

Server has PHP Version 4.3.10 and in 2.0.11 keeps Santy out as I know. But any suggestions or solution to my problem?
Title: Re: [Possibly unsolved]: Possible bug?
Post by: Joachim Müller on January 07, 2005, 11:51:51 AM
What version of the Zend Optimizer (ZO) do you have?

Joachim
Title: Re: [Possibly unsolved]: Possible bug?
Post by: Streamer on January 07, 2005, 12:09:33 PM
Quote from: GauGau on January 07, 2005, 11:51:51 AM
What version of the Zend Optimizer (ZO) do you have?

Server has only "Zend Extension 20021010", no Zend Optimizer, checked from phpinfo().
Title: Re: [Possibly unsolved]: Possible bug?
Post by: Streamer on January 07, 2005, 05:25:17 PM
Because solution to problem not found I took back in use use working 1.2 from backup. If someone wants to still see the error message, I keep 1.3.2 temporary up at [removed] (unfortunately I have to now use Finnish language and customised theme).

Hopefully somebody founds someday solution to this problem, until that i keep using old version.
Title: Re: [Possibly unsolved]: Possible bug?
Post by: Streamer on January 07, 2005, 08:56:28 PM
Solved! :)

There seems to be incorrect information on documentation, there is written that:

5.3 Integration steps
5.3.1 Check your bbs settings

"If you are using phpBB 2, go to the admin control panel and check that "Cookie domain" corresponds to your domain, "Cookie name" is "phpbb2mysql" and "Cookie path" is "/". "

If I get it right this means that phpbb and cpg cookie name must be same, and yes that worked fine like that with 1.2 but in 1.3.2 those must be different! Working fine now when those are changed to different names.

Title: Re: [Possibly unsolved]: Possible bug?
Post by: Nibbler on January 07, 2005, 09:00:49 PM
It says:

QuoteImportant: the cookie names of your bbs and coppermine must not be the same - they must differ!
Title: Re: [Invalid]: Possible bug?
Post by: Joachim Müller on January 08, 2005, 04:36:26 AM
Quote from: Streamer on January 07, 2005, 08:56:28 PMIf I get it right this means that phpbb and cpg cookie name must be same
no, you got this wrong.

Quote from: Streamer on January 07, 2005, 08:56:28 PMand yes that worked fine like that with 1.2 but in 1.3.2 those must be different!
This has been the same with all versions of coppermine, none of them allowed you to have the same cookie name for your bbs and coppermine (just because this is the basic concept of cookies), so in fact your posting is a bit inadequate that says it used to be the same with the cpg1.2.x install. The cookie names must always differ, that's what the documentation says. If your cpg1.2 install used to work, you must have had different cookie names - it wouldn't have worked if they were the same.

Glad you were able to fix this for yourself, but you drew the wrong conclusions ;).

Joachim

Title: Re: [Invalid]: Possible bug?
Post by: Streamer on January 08, 2005, 12:29:44 PM
Okey, I got it wrong, im stupid :)