4images Forum & Community

4images Issues / Ausgaben => Installation, Update & Configuration => Topic started by: freediver on July 16, 2008, 06:31:47 PM

Title: 1.7.6 not working after server upgraded to mysql 5
Post by: freediver on July 16, 2008, 06:31:47 PM
I have looked for a solution and I can't find one on the forum.

Here are some mistakes in my log file

16-Jul-2008 08:33:38] PHP Notice:  Undefined index:  cat_id in iincludes/functions.php on line 358
[16-Jul-2008 08:33:38] PHP Notice:  Undefined index:  image_id in includes/functions.php on line 362
[16-Jul-2008 08:33:38] PHP Notice:  Undefined index:  image_media_file in includes/functions.php on line 384
[16-Jul-2008 08:33:38] PHP Notice:  Undefined index:  image_id in includes/functions.php on line 405
[16-Jul-2008 08:33:38] PHP Notice:  Undefined index:  user_id in includes/functions.php on line 406
[16-Jul-2008 08:33:38] PHP Notice:  Undefined index:  image_name in includes/functions.php on line 409

The site is www.zoomwallpapers.com
Title: Re: 1.7.6 not working after server upgraded to mysql 5
Post by: KurtW on July 16, 2008, 07:07:24 PM
Hi,

version 1.7.6 is mysql5 compatible  :wink:

i thing, you have mods included without mysql5 compatible code....

=> http://www.4homepages.de/forum/index.php?topic=10184.15


Kurt
Title: Re: 1.7.6 not working after server upgraded to mysql 5
Post by: Acidgod on July 17, 2008, 12:20:27 AM
it is a windows server?

open global.php

search
error_reporting(E_ERROR | E_WARNING | E_PARSE);

replace with
//error_reporting(E_ERROR | E_WARNING | E_PARSE);
Title: Re: 1.7.6 not working after server upgraded to mysql 5
Post by: KurtW on July 17, 2008, 06:09:25 AM
And the other erros, e.g index.php:
Quote
An unexpected error occured. Please try again later.

An unexpected error occured. Please try again later.

Warning: Cannot modify header information - headers already sent by (output started at /home/prelovac/public_html/zoomwallpapers/includes/db_mysql.php:192) in /home/prelovac/public_html/zoomwallpapers/includes/sessions.php on line 101

Warning: Cannot modify header information - headers already sent by (output started at /home/prelovac/public_html/zoomwallpapers/includes/db_mysql.php:192) in /home/prelovac/public_html/zoomwallpapers/includes/sessions.php on line 101

An unexpected error occured. Please try again later.

An unexpected error occured. Please try again later.


Kurt
Title: Re: 1.7.6 not working after server upgraded to mysql 5
Post by: freediver on July 17, 2008, 09:44:44 AM
Thanks for brisk response.

The server is linux. The error_reporting tweak did not solve it.

"An unexpected error occured. Please try again later." is a message from script when a db error occurs. That is why the headers are already sent before the page comes.

The link KurtW provided contains patches that are already implemented in my source. I am using 1.7.6 and problems started when the server decided to upgrade to mysql 5.

The hosting says they can not inspect my "custom" script.

I do use some plugins but nothing fancy maybe one or two plugins. One is Photo of the Day.  The other one is for admin so it is not important.

Any help appreciated.



Title: Re: 1.7.6 not working after server upgraded to mysql 5
Post by: Acidgod on July 17, 2008, 10:55:57 AM
please post the code from the sessions.php...  :D
Title: Re: 1.7.6 not working after server upgraded to mysql 5
Post by: freediver on July 17, 2008, 04:03:32 PM
Here you go Acidgod:

http://www.zoomwallpapers.com/src/sessions.zip
Title: Re: 1.7.6 not working after server upgraded to mysql 5
Post by: Acidgod on July 17, 2008, 11:04:06 PM
hmmm...

an the db_mysql.php please...
Title: Re: 1.7.6 not working after server upgraded to mysql 5
Post by: freediver on July 18, 2008, 12:44:23 PM
Here is the whole includes/

http://www.zoomwallpapers.com/src/includes.zip

I appreciate your time trying to figure out the problem.
Title: Re: 1.7.6 not working after server upgraded to mysql 5
Post by: V@no on July 18, 2008, 03:06:58 PM
In includes/functions.php find:
Code: [Select]
            FROM ".IMAGES_TABLE." i,  ".CATEGORIES_TABLE." c
Replace with:
Code: [Select]
            FROM (".IMAGES_TABLE." i,  ".CATEGORIES_TABLE." c)
That should fix your Photo Of The Day mod, but if you installed other mods, you might want look for similar lines to change.
Title: Re: 1.7.6 not working after server upgraded to mysql 5
Post by: freediver on July 19, 2008, 03:22:36 PM
The last tip was helpful and I replaced similar queries  (there was one - it was lightbox, dont know if that is standard part of 4images).

At the end I had to do REPAIR TABLE 4images_sessions

Thanks everyone for assistance.