Error, can not view pictures after upgrading Error, can not view pictures after upgrading
 

News:

cpg1.5.48 Security release - upgrade mandatory!
The Coppermine development team is releasing a security update for Coppermine in order to counter a recently discovered vulnerability. It is important that all users who run version cpg1.5.46 or older update to this latest version as soon as possible.
[more]

Main Menu

Error, can not view pictures after upgrading

Started by Fullpupp, September 28, 2004, 09:42:28 AM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

Fullpupp

After I upgraded from 1.2.0 to 1.3.2, i cannot view the pictures from the older version. When I try to view them, I get this message:

Fatal error: Maximum execution time of 30 seconds exceeded in /home/fullpupp/public_html/bilder/include/functions.inc.php on line 79

Other functions works fine, except "my gallery".

Some failure occured before upgrading to.. I mistakingly deleted some categories, and then I couldn't enter "my gallery". Anyone have any idea how I could fix this?

Joachim Müller

post a link to your gallery, and a deep link to the page in question.

Joachim

Fullpupp

The adress is

www.fullpupp.com/bilder/

You can try to access any picture, and it would not respond. I've created a guest account:

Username: Guest
Password: 1234


Casper

The pics are there ok.  Make sure your ftp program replaced ALL the files when you did the update.

It does not seem to want to display displayimage.php. 

I also suggest you put catlist and alblist in the 'contents of main page' in config.  Coppermine usually needs these.
It has been a long time now since I did my little bit here, and have done no coding or any other such stuff since. I'm back to being a noob here

Tranz

As Casper stated, the pictures are OK. You can check by going to the direct address location of the photo files. While I checked, I noticed that you have your photos located in the userpics folder. With version 1.3+ you will no longer be able to batch upload files if you upload them into that folder.

Fullpupp

Thanks for the tips! :)

I replaced all files except those stated in the readme-file. The displayimage.php is there..

I wonder, if I move them to the album folder, would the ratings, and comments follow them?

Tranz

For the photos you currently have, do not move them while outside of CPG, unless you know how to manually edit the database to note their new locations. It's only with new uploads that you would be unable to use userpics because you're not going to be able to see the folder.


I got this error message when I clicked on one of the photo thumbnails:
Quote
Fatal error: Maximum execution time of 30 seconds exceeded in /home/fullpupp/public_html/bilder/include/functions.inc.php on line 79
Are you using an unmodified version of that functions file? If not would you be able to post for us line 79 (+/- few lines) of your copy of the file?

Casper

Please send me, by pm, an admin login to your site.  There is something fishy with your install.
It has been a long time now since I did my little bit here, and have done no coding or any other such stuff since. I'm back to being a noob here

Fullpupp

Quote<?php
// ------------------------------------------------------------------------- //
// Coppermine Photo Gallery 1.3.2                                            //
// ------------------------------------------------------------------------- //
// Copyright (C) 2002-2004 Gregory DEMAR                                     //
// http://www.chezgreg.net/coppermine/                                       //
// ------------------------------------------------------------------------- //
// Updated by the Coppermine Dev Team                                        //
// (http://coppermine.sf.net/team/)                                          //
// see /docs/credits.html for details                                        //
// ------------------------------------------------------------------------- //
// This program is free software; you can redistribute it and/or modify      //
// it under the terms of the GNU General Public License as published by      //
// the Free Software Foundation; either version 2 of the License, or         //
// (at your option) any later version.                                       //
// ------------------------------------------------------------------------- //
// CVS version: $Id: functions.inc.php,v 1.14 2004/08/14 17:30:15 gaugau Exp $
// ------------------------------------------------------------------------- //

/**************************************************************************
   Function for managing cookie saved user profile
**************************************************************************/

// Decode the user profile contained in a cookie
function user_get_profile()
{
        global $CONFIG, $USER, $HTTP_COOKIE_VARS;

        if (isset($HTTP_COOKIE_VARS[$CONFIG['cookie_name'].'_data'])) {
                $USER = @unserialize(@base64_decode($HTTP_COOKIE_VARS[$CONFIG['cookie_name'].'_data']));
        }

        if (!isset($USER['ID']) || strlen($USER['ID']) != 32) {
                list($usec, $sec) = explode(' ', microtime());
                $seed = (float) $sec + ((float) $usec * 100000);
                srand($seed);
                $USER=array('ID' => md5(uniqid(rand(),1)));
        } else {
                $USER['ID'] = addslashes($USER['ID']);
        }

        if (!isset($USER['am'])) $USER['am'] = 1;
}

// Save the user profile in a cookie
function user_save_profile()
{
        global $CONFIG, $USER, $HTTP_SERVER_VARS;

        $data = base64_encode(serialize($USER));
        setcookie($CONFIG['cookie_name'].'_data', $data, time()+86400*30, $CONFIG['cookie_path']);
}

/**************************************************************************
   Database functions
**************************************************************************/

// Connect to the database
function cpg_db_connect()
{
        global $CONFIG;
        $result = @mysql_connect($CONFIG['dbserver'], $CONFIG['dbuser'], $CONFIG['dbpass']);
        if (!$result)
                return false;
        if (!mysql_select_db($CONFIG['dbname']))
                return false;
        return $result;
}

// Perform a database query
function db_query($query, $link_id = 0)
{
        global $CONFIG, $query_stats, $queries;

        $query_start = cpgGetMicroTime();
        if (($link_id)) {
            $result = mysql_query($query, $link_id);
        } else {
                $result = mysql_query($query);      //Line 79
        }
        $query_end = cpgGetMicroTime();
        if (isset($CONFIG['debug_mode']) && (($CONFIG['debug_mode']==1) || ($CONFIG['debug_mode']==2) )) {
                $query_stats[] = $query_end - $query_start;
                $queries[] = $query;
        }
        if (!$result) db_error("While executing query \"$query\" on $link_id");

        return $result;
}

I only posted the first functions, including the one with line 79.

I have not modified this file in any way... :-\\