Updating gallery v1 - I'm a total newbie !!!

Mike_Para
Mike_Para's picture

Joined: 2010-01-11
Posts: 29
Posted: Mon, 2010-01-11 18:11

Gallery URL: http://gti.peugeot205.pl/gallery/
Gallery version: Gallery v1.5.2-pl2 . released on 02/07/06
Apache version:
PHP version: PHP v5.3.1
Graphics Toolkit: ImageMagick ?
Operating system: MacOS X v10.6.2
Web browser/version (if applicable): Firefox/Safari

Hello,

This is my first topic here, I just registered in hope that I will get some help from you guys. I was using the Gallery v1 for a long time and I didn't had any troubles, there is a big database with pictures there and loosing them would be disaster as the gallery is connected to a main website where is lots of people.

Few months ago I started to have this problem, lots of messages show up, plenty of text like this here...

Quote:
Deprecated: Assigning the return value of new by reference is deprecated in /home/peugeot/public_html/gti/gallery/classes/Mail/htmlMimeMail.php on line 407

Deprecated: Assigning the return value of new by reference is deprecated in /home/peugeot/public_html/gti/gallery/classes/Mail/htmlMimeMail.php on line 423

Deprecated: Assigning the return value of new by reference is deprecated in /home/peugeot/public_html/gti/gallery/classes/Mail/htmlMimeMail.php on line 434

Deprecated: Assigning the return value of new by reference is deprecated in /home/peugeot/public_html/gti/gallery/classes/Mail/htmlMimeMail.php on line 447

Deprecated: Assigning the return value of new by reference is deprecated in /home/peugeot/public_html/gti/gallery/classes/Mail/htmlMimeMail.php on line 461

Deprecated: Function eregi_replace() is deprecated in /home/peugeot/public_html/gti/gallery/init.php on line 138

Deprecated: Function eregi_replace() is deprecated in /home/peugeot/public_html/gti/gallery/init.php on line 140

Deprecated: Function set_magic_quotes_runtime() is deprecated in /home/peugeot/public_html/gti/gallery/init.php on line 163

Deprecated: Function ereg() is deprecated in /home/peugeot/public_html/gti/gallery/lib/lang.php on line 620

Deprecated: Function ereg() is deprecated in /home/peugeot/public_html/gti/gallery/lib/lang.php on line 620

Deprecated: Function ereg() is deprecated in /home/peugeot/public_html/gti/gallery/lib/lang.php on line 620

Deprecated: Function ereg() is deprecated in /home/peugeot/public_html/gti/gallery/classes/AlbumDB.php on line 53

Deprecated: Function split() is deprecated in /home/peugeot/public_html/gti/gallery/classes/Album.php on line 95

I can bet you've seen this message before... So I'm not very good in php and all the server things, that's why I am here. I've downloaded new beta version of Gallery V3 and I would like to use it now. I thought having the problem above is a good push for a change to something newer and better.

I'm afraid to do this on my own as I'm afraid to lost all the pictures :/ Can someone help me here ? I have full access to the server + I can give all the information. Also I've downloaded a new gallery and I've copied it to the server so it should be ready to go !

I will be checking often the topic so hopefully we can resolve the problem quickly.

Thanks and sorry for my English,
Mike

 
nivekiam
nivekiam's picture

Joined: 2002-12-10
Posts: 16504
Posted: Mon, 2010-01-11 19:06
Quote:
Deprecated: Assigning the return value of new by reference is deprecated in

That looks like you're using a newer version of PHP. Ah, yes PHP 5.3.1. To continue using G1, you're either going to need to down grade PHP to 5.2.x, upgrade to G2 2.3.1 or possibly migrate over to Jallery (where Jens is taking off with where G1 was left and moving ahead) www.jallery.com (looks like he's been redoing the site there). Gallery 1 is no longer developed and only supported as best as we can.

Here are instructions on migrating from G1 to G2.

FAQ: Can I update from G1 -> G2?
____________________________________________
Like Gallery? Like the support? Donate now!!! See G2 live here

 
Mike_Para
Mike_Para's picture

Joined: 2010-01-11
Posts: 29
Posted: Mon, 2010-01-11 19:07

Thanks, I will read this , hopefully I will be ok. Can I count on your help in case I will lost somewhere on the way.

 
nivekiam
nivekiam's picture

Joined: 2002-12-10
Posts: 16504
Posted: Mon, 2010-01-11 19:20

If it's G1 related it really depends on the question. Most likely yes, or someone else can. It's just been years since I've really ran and used G1 :)
____________________________________________
Like Gallery? Like the support? Donate now!!! See G2 live here

 
Tim_j
Tim_j's picture

Joined: 2002-08-15
Posts: 6818
Posted: Mon, 2010-01-11 19:24

Hello

Open init.php

find error_reporting(E_ALL & ~E_NOTICE);
(All occurrences)

change to error_reporting(E_ALL & ~E_NOTICE & ~E_DEPRECATED);

Jens
--
Gallery 1 Developer

 
nivekiam
nivekiam's picture

Joined: 2002-12-10
Posts: 16504
Posted: Mon, 2010-01-11 19:28

Awesome! Thanks Jens!
____________________________________________
Like Gallery? Like the support? Donate now!!! See G2 live here

 
Mike_Para
Mike_Para's picture

Joined: 2010-01-11
Posts: 29
Posted: Mon, 2010-01-11 19:48

Thanks, I've change it but it's still giving me a problem.

 
Tim_j
Tim_j's picture

Joined: 2002-08-15
Posts: 6818
Posted: Mon, 2010-01-11 20:53

My mistake. Add a ~ before E_DEPRECATED

Jens
--
Gallery Developer

 
Mike_Para
Mike_Para's picture

Joined: 2010-01-11
Posts: 29
Posted: Mon, 2010-01-11 21:06

Great, everything working fine now. Thank you very much

 
Mike_Para
Mike_Para's picture

Joined: 2010-01-11
Posts: 29
Posted: Thu, 2010-01-14 14:00

Hello,

That's me again, I have another problem which appeared as soon as I resolved the first one. Now when I'm trying to upload an image it showing me this:

Quote:
Processing status...
******Adding imgyf.jpg*****

Warning: exec() has been disabled for security reasons in /home/peugeot/public_html/gti/gallery/util.php on line 1204

Warning: exec() has been disabled for security reasons in /home/peugeot/public_html/gti/gallery/util.php on line 1204

Warning: exec() has been disabled for security reasons in /home/peugeot/public_html/gti/gallery/platform/fs_unix.php on line 45

Error: Unable to make thumbnail (0)

One more time I'm asking for help.

Thanks in advance,
Mike

 
Tim_j
Tim_j's picture

Joined: 2002-08-15
Posts: 6818
Posted: Thu, 2010-01-14 14:29

Hello Mike,

with this PHP configuration you can not use Gallery 1.x

Jens
--
Gallery 1 Developer

 
Mike_Para
Mike_Para's picture

Joined: 2010-01-11
Posts: 29
Posted: Thu, 2010-01-14 15:31

Tim would you be able to help me updating to 2. via MSN ? it's

 
Tim_j
Tim_j's picture

Joined: 2002-08-15
Posts: 6818
Posted: Thu, 2010-01-14 21:15

via MSN?

Think 15 Minutes about your request then answer the question by yourself in an adequate manner.

Jens

 
Mike_Para
Mike_Para's picture

Joined: 2010-01-11
Posts: 29
Posted: Thu, 2010-01-14 22:16

Yes, why not ? :D

 
nivekiam
nivekiam's picture

Joined: 2002-12-10
Posts: 16504
Posted: Thu, 2010-01-14 22:46

We do this for free, in our free time :)

Read this:
FAQ: Can I update from G1 -> G2?
____________________________________________
Like Gallery? Like the support? Donate now!!! See G2 live here

 
aberkvam

Joined: 2004-07-21
Posts: 9
Posted: Mon, 2010-01-18 19:53

After upgrading to PHP 5.3.0 my error logs exploded in size. They increased by 100 times, on average. Gallery 1.x was not the only source of the log bloat but it was a major source.

Changing the error log level in php.ini didn't help since Gallery sets its own error log levels. This post was a huge help in figuring out how to override the logging in Gallery. As PHP 5.3.x becomes more widespread, this question will come up more and more. I think it would be a very good idea to add it to the FAQ. (Maybe folks like http://jems.de/gallery-legacy/album01 could figure out how to get the error messages off of their pages then. ;-) )

The line "error_reporting(E_ALL & ~E_NOTICE);" does appear twice in the init.php file. (In 1.5.7, anyway. Looks like that was changed by 1.5.10?). Just changing the first occurrence doesn't work.

As far as tech support via MSN, this is another reason it's a bad idea. If this exchange had been over MSN, I never would have found it in a search and I wouldn't have been able to solve my problem based on your experiences. Forum-based support lets us share knowledge and solutions.

 
Mike_Para
Mike_Para's picture

Joined: 2010-01-11
Posts: 29
Posted: Thu, 2010-01-21 16:47

Ok, fair enough. I will try here, I've downloaded Gallery2 and it's already on the server. After trying to run it , such a message appears

Link to OLD gallery is: http://gti.peugeot205.pl/gallery/
Link to NEW: http://gti.peugeot205.pl/gallery2/

Quote:
Warning: require_once(/home/peugeot/public_html/gti/gallery2/modules/core/classes/Gallery.class) [function.require-once]: failed to open stream: No such file or directory in /home/peugeot/public_html/gti/gallery2/bootstrap.inc on line 33

Fatal error: require_once() [function.require]: Failed opening required '/home/peugeot/public_html/gti/gallery2/modules/core/classes/Gallery.class' (include_path='.:/usr/lib/php:/usr/local/lib/php') in /home/peugeot/public_html/gti/gallery2/bootstrap.inc on line 33

Thanks in advance,
Mike

 
nivekiam
nivekiam's picture

Joined: 2002-12-10
Posts: 16504
Posted: Thu, 2010-01-21 16:54

Your upload didn't complete:
example: http://gti.peugeot205.pl/gallery2/modules/
example: http://gti.peugeot205.pl/gallery2/themes

You're missing 1000s of files
____________________________________________
Like Gallery? Like the support? Donate now!!! See G2 live here

 
Mike_Para
Mike_Para's picture

Joined: 2010-01-11
Posts: 29
Posted: Thu, 2010-01-21 17:08

ok, i've upladed whole thing again, I run the installation and pass the authorisation, there is one warning:

Quote:
Warning: The exec() function is disabled in your PHP by the disabled_functions parameter in php.ini. You won't be able to use modules that require external binaries (e.g. ImageMagick, NetPBM or Ffmpeg). This can only be set server-wide, so you will need to change it in the global php.ini.

Should I continue .. ?

 
nivekiam
nivekiam's picture

Joined: 2002-12-10
Posts: 16504
Posted: Thu, 2010-01-21 17:12

You can continue, but you can only use GD, you can't use ImageMagick or NetPBM or any other external binary. This is no different than G1 (or G3)
____________________________________________
Like Gallery? Like the support? Donate now!!! See G2 live here

 
Mike_Para
Mike_Para's picture

Joined: 2010-01-11
Posts: 29
Posted: Thu, 2010-01-21 17:13

That mean gallery will still be all right ? I mean, thumbnails will show up and there will be no problem with uploading pictures (as I have now with gallery1) ?

 
nivekiam
nivekiam's picture

Joined: 2002-12-10
Posts: 16504
Posted: Thu, 2010-01-21 17:23

It should work. But GD consumes more resources (memory allotted to PHP) so depending on the limits your host has put into place you may run into issues, but probably not much different than you'd have with G1.

____________________________________________
Like Gallery? Like the support? Donate now!!! See G2 live here

 
Mike_Para
Mike_Para's picture

Joined: 2010-01-11
Posts: 29
Posted: Thu, 2010-01-21 17:29

the main issue I have with G1 is that members are unable to upload pictures... Anyway, I will continue with installation. Any tips what should I do during installation to keep all the old images from G1 ??

I stopped at point 5: DATABASE SETUP

Quote:
Database type:
DB Hostname:
DB Username:
DB Password:
DB Name:
Table Prefix:
Column Prefix:

Should I access my admin panel and create a new database ?

 
nivekiam
nivekiam's picture

Joined: 2002-12-10
Posts: 16504
Posted: Thu, 2010-01-21 17:34

Yes, or use a different prefix. Test it and try it. You don't need to do anything during install. Just don't put G2 in the same place as G1.

Read this guide and the detailed guide it links to:
FAQ: Can I update from G1 -> G2?
____________________________________________
Like Gallery? Like the support? Donate now!!! See G2 live here

 
Mike_Para
Mike_Para's picture

Joined: 2010-01-11
Posts: 29
Posted: Thu, 2010-01-21 17:54

I made a database with username: peugeot_mike and database name: peugeot_galeria2 , where should I put those information in ?

Database type:
DB Hostname:
DB Username:
DB Password:
DB Name:
Table Prefix:
Column Prefix:

it doesn't seems to work for me :/ what should I put in table prefix and column prefix ?

 
nivekiam
nivekiam's picture

Joined: 2002-12-10
Posts: 16504
Posted: Thu, 2010-01-21 18:02
 
Mike_Para
Mike_Para's picture

Joined: 2010-01-11
Posts: 29
Posted: Thu, 2010-01-21 18:11

Ok I manage to move further, and I finished the installation, on the way (about step 8) i got such a message

Quote:
Warning: ini_set() has been disabled for security reasons in /home/peugeot/public_html/gti/gallery2/modules/core/classes/Gallery.class on line 673

Warning: ini_set() has been disabled for security reasons in /home/peugeot/public_html/gti/gallery2/modules/core/classes/Gallery.class on line 674

Warning: ini_set() has been disabled for security reasons in /home/peugeot/public_html/gti/gallery2/modules/core/classes/Gallery.class on line 675

Warning: ini_set() has been disabled for security reasons in /home/peugeot/public_html/gti/gallery2/modules/core/classes/Gallery.class on line 676

Warning: ini_set() has been disabled for security reasons in /home/peugeot/public_html/gti/gallery2/init.inc on line 32

Warning: ini_set() has been disabled for security reasons in /home/peugeot/public_html/gti/gallery2/init.inc on line 33

And few more on the gallery main page http://gti.peugeot205.pl/gallery2/main.php

After logging in:

Quote:
Warning: ini_set() has been disabled for security reasons in /home/peugeot/public_html/gti/gallery2/init.inc on line 32

Warning: ini_set() has been disabled for security reasons in /home/peugeot/public_html/gti/gallery2/init.inc on line 33

Warning: Cannot modify header information - headers already sent by (output started at /home/peugeot/public_html/gti/gallery2/init.inc:32) in /home/peugeot/public_html/gti/gallery2/modules/core/classes/GalleryPhpVm.class on line 142

 
nivekiam
nivekiam's picture

Joined: 2002-12-10
Posts: 16504
Posted: Thu, 2010-01-21 18:14

Post a link to phpinfo:
FAQ: How do I create a phpinfo page?
____________________________________________
Like Gallery? Like the support? Donate now!!! See G2 live here

 
Mike_Para
Mike_Para's picture

Joined: 2010-01-11
Posts: 29
Posted: Thu, 2010-01-21 18:35
 
nivekiam
nivekiam's picture

Joined: 2002-12-10
Posts: 16504
Posted: Thu, 2010-01-21 18:59

Two options I see, in order of preference

Ask your host to change it so that function is enabled

Dig through the code and comment out every line that tries to use that function (this may effect how G2 behaves in certain areas)

These restrictions may also be the cause of issues with G1 too, but Jens would be better to answer that.

____________________________________________
Like Gallery? Like the support? Donate now!!! See G2 live here

 
Mike_Para
Mike_Para's picture

Joined: 2010-01-11
Posts: 29
Posted: Thu, 2010-01-21 20:09

Ok, everything is sorted now. http://gti.peugeot205.pl/gallery2/main.php Thanks for help, i wouldn't be able to do this without you.

could you stay with me for a while and help me to migrate all the pictures and albums from old gallery please ?

 
nivekiam
nivekiam's picture

Joined: 2002-12-10
Posts: 16504
Posted: Thu, 2010-01-21 20:15

read this:
FAQ: Can I update from G1 -> G2?

And everything that FAQ links to
____________________________________________
Like Gallery? Like the support? Donate now!!! See G2 live here

 
Mike_Para
Mike_Para's picture

Joined: 2010-01-11
Posts: 29
Posted: Thu, 2010-01-21 21:07

Will do ! During the Pre-Migration preparation, while checking for "orphans" I'm getting lots of messages like here, but no orphans at the end. Is that something serious ? Can I continue ?

http://gti.peugeot205.pl/gallery/tools/find_orphans.php

..... I went further, I changed the name of the old gallery to g1 and update the .htaccess file as I couldn't see my gallery after this. I still can't see it when I'm choosing a gallery address http://gti.peugeot205.pl/g1

Quote:
Warning: mkdir() [function.mkdir]: No such file or directory in /home/peugeot/public_html/gti/g1/classes/gallery/UserDB.php on line 43
Error: Unable to create dir: /home/peugeot/public_html/gti/gallery/albums/.users
Fatal error: Call to a member function getUsername() on a non-object in /home/peugeot/public_html/gti/g1/classes/gallery/UserDB.php on line 119

After accessing setup on http://gti.peugeot205.pl/g1/setup I'm getting such a message...

Quote:
Deprecated: Function ereg() is deprecated in /home/peugeot/public_html/gti/g1/lib/popup.php on line 35

Deprecated: Function ereg() is deprecated in /home/peugeot/public_html/gti/g1/lib/popup.php on line 35

Deprecated: Function ereg() is deprecated in /home/peugeot/public_html/gti/g1/lib/popup.php on line 35

Deprecated: Function ereg() is deprecated in /home/peugeot/public_html/gti/g1/lib/popup.php on line 35

Deprecated: Function ereg_replace() is deprecated in /home/peugeot/public_html/gti/g1/lib/url.php on line 99

Warning: mkdir() [function.mkdir]: No such file or directory in /home/peugeot/public_html/gti/g1/classes/gallery/UserDB.php on line 43
Error: Unable to create dir: /home/peugeot/public_html/gti/gallery/albums/.users
Deprecated: Function ereg_replace() is deprecated in /home/peugeot/public_html/gti/g1/lib/url.php on line 99
Upgrading Users
The user database in your gallery was created with an older version of the software and is out of date. This is not a problem! We will upgrade it. This may take some time. Your data will not be harmed in any way by this process. Rest assured, that if this process takes a long time now, it's going to make your gallery run more efficiently in the future.
If you get an error, and only some users are upgraded, try refreshing the page to upgrade remaining users.

Please Wait...
Fatal error: Call to a member function getUsername() on a non-object in /home/peugeot/public_html/gti/g1/classes/gallery/UserDB.php on line 341

I went through this http://codex.gallery2.org/Gallery2:migration#Notes and change config.php so the line of the gallery will be g1 instead of gallery and it's still showing me these lines

Quote:
Parse error: syntax error, unexpected '=', expecting T_STRING or T_VARIABLE or '{' or '$' in /home/peugeot/public_html/gti/g1/config.php on line 171

 
nivekiam
nivekiam's picture

Joined: 2002-12-10
Posts: 16504
Posted: Thu, 2010-01-21 21:53
Quote:
Parse error: syntax error, unexpected '=', expecting T_STRING or T_VARIABLE or '{' or '$' in /home/peugeot/public_html/gti/g1/config.php on line 171

You made a typo or something like that. Look on line 171 of config.php
____________________________________________
Like Gallery? Like the support? Donate now!!! See G2 live here

 
Mike_Para
Mike_Para's picture

Joined: 2010-01-11
Posts: 29
Posted: Fri, 2010-01-22 10:09
 
Mike_Para
Mike_Para's picture

Joined: 2010-01-11
Posts: 29
Posted: Fri, 2010-01-22 11:40

I put back the original config.php and it shows me this:

Quote:
Warning: mkdir() [function.mkdir]: No such file or directory in /home/peugeot/public_html/gti/g1/classes/gallery/UserDB.php on line 43
Error: Unable to create dir: /home/peugeot/public_html/gti/gallery/albums/.users
Upgrading Users
The user database in your gallery was created with an older version of the software and is out of date. This is not a problem! We will upgrade it. This may take some time. Your data will not be harmed in any way by this process. Rest assured, that if this process takes a long time now, it's going to make your gallery run more efficiently in the future.
If you get an error, and only some users are upgraded, try refreshing the page to upgrade remaining users.

Please Wait...
Fatal error: Call to a member function getUsername() on a non-object in /home/peugeot/public_html/gti/g1/classes/gallery/UserDB.php on line 341

Totally relly on your help now...

 
Tim_j
Tim_j's picture

Joined: 2002-08-15
Posts: 6818
Posted: Fri, 2010-01-22 19:34

This mostly appears, when the albums folder is not there and/or is not writable by the webserver user.

Jens
--
Gallery Developer

 
Mike_Para
Mike_Para's picture

Joined: 2010-01-11
Posts: 29
Posted: Sat, 2010-01-23 21:50

how can I fix it ? I was trying to change writable permissions of the folder but it didn't change anything... ;/

 
Tim_j
Tim_j's picture

Joined: 2002-08-15
Posts: 6818
Posted: Sat, 2010-01-23 22:26

I don't know what the permissions are. Neither if the setting in config.php is correct.

Jens
--
Gallery Developer

 
Mike_Para
Mike_Para's picture

Joined: 2010-01-11
Posts: 29
Posted: Mon, 2010-01-25 14:37

I don't know what to do :/ I'm stopped on updating from G1 to G2...

 
Mike_Para
Mike_Para's picture

Joined: 2010-01-11
Posts: 29
Posted: Sat, 2010-01-30 19:22

Please, what can I do to finish upgrading ? I need your help

 
Tim_j
Tim_j's picture

Joined: 2002-08-15
Posts: 6818
Posted: Mon, 2010-02-01 19:42

Hello Mike,

at which point are you right now? Do you have a working (= you can see your albums) Gallery 1?
Or something between G1 and G2?

Jens
--
Gallery 1 Developer

 
Mike_Para
Mike_Para's picture

Joined: 2010-01-11
Posts: 29
Posted: Wed, 2010-02-03 14:06

Hi Tim,

No I can't see the albums and I don't know why, as soon as I changed the name of the folder I'm getting such a message

http://gti.peugeot205.pl/g1/

 
Mike_Para
Mike_Para's picture

Joined: 2010-01-11
Posts: 29
Posted: Wed, 2010-02-03 15:26

OK, somehow I manage to run my old gallery in the new address after renaming the folder: it's working now http://gti.peugeot205.pl/g1/albums.php but after clicking on each album it showing me that there is no such a website :/

Please help

 
Mike_Para
Mike_Para's picture

Joined: 2010-01-11
Posts: 29
Posted: Wed, 2010-02-03 20:05

I need to change some lines in .htaccess file. But every time i'm trying to download it to the HDD it just dissapeard or it doesn't seems to download. When I'm trying to edit it straight from the server it opens as a blank page....

I'm using fetch and BBedit or Coda, on Mac OS

What should I do to edit .htaccess file ?

 
Mike_Para
Mike_Para's picture

Joined: 2010-01-11
Posts: 29
Posted: Thu, 2010-02-04 13:17

Guys I manage to sort the gallery. It's working now. I have a qustion, how can I change the size of the font under the thumbnail of the picture ??

Also , can I upload more images at a time ? Maybe a .zip pack ?

 
nivekiam
nivekiam's picture

Joined: 2002-12-10
Posts: 16504
Posted: Thu, 2010-02-04 19:39

For upload read this:
http://codex.gallery2.org/Gallery2:How_to_Add_Items

Here's the method I normally use:
http://codex.gallery2.org/Gallery2:How_to_Add_Items#How_to_Add_Items_from_the_Local_Server_.28or_with_FTP.29

For the size of the text, fire up Firefox, install the Firebug extension (if you haven't already) and you can inspect any element of the page to see what CSS it's using. There are several different CSS class names for text under the thumbnails so it would really depend on what you're looking at. A screenshot highlighting what you want to change would be helpful, but it's most likely either:

.giDescription or .giTitle

You can edit /themes/YourTheme/local/theme.css

See this page about editing themes and templates and why you'd want to create a local directory:
http://codex.gallery2.org/Gallery2:Editing_Templates
____________________________________________
Like Gallery? Like the support? Donate now!!! See G2 live here

 
Mike_Para
Mike_Para's picture

Joined: 2010-01-11
Posts: 29
Posted: Fri, 2010-02-05 09:35

Thanks, that firebug is a very usefull tool http://gti.peugeot205.pl/gallery/main.php