Community @ The Turning Gate

Support community for TTG plugins and products.

You are not logged in.

#1 2018-11-09 00:08:15

oeni4711
Member
Registered: 2013-11-21
Posts: 20

TTG CE3 and PHP 7(.2)

Hi,
somehow I haven't noticed my hosting provider's announcement to shut down PHP 5.6 and move to 7.2.
Now me and my clients can't access my TTG CE3 gallery and I can't access my CE Publisher albums in LR.
Is there anything I can do (quickly)?
I have two shows this weekend :-(
http://fot-o-box.de/galerie/
Best,
Oliver

Offline

#2 2018-11-09 00:17:03

oeni4711
Member
Registered: 2013-11-21
Posts: 20

Re: TTG CE3 and PHP 7(.2)

In Publisher's code at publisher/api/lib/markdown.php there's a "Markdown_Parser" class with a function of same name which is deprecated.

In CE3 WP Theme's function.php: Declaration of My_Walker_Nav_Menu::start_lvl(&$output, $depth) should be compatible with Walker_Nav_Menu::start_lvl(&$output, $depth = 0, $args = Array)

Offline

#3 2018-11-09 00:49:33

rod barbee
Moderator
From: Port Ludlow, WA USA
Registered: 2012-09-24
Posts: 15,060
Website

Re: TTG CE3 and PHP 7(.2)

The quickest fix would be to roll back your site's php version to 5.6 if your host allows. You should be able to do this from your C-Panel or by contacting your host.

As far as changing the code, Matt or Ben will need to weigh in on whether it's feasible. Don't be surprised if there is no quick fix as CE3 is long discontinued.

In the long run, updating your site to Backlight is the best option.


Rod 
Just a user with way too much time on his hands.
www.rodbarbee.com
ttg-tips.com, Pangolin test site, Backlight 1.1.1 test site

Offline

#4 2018-11-09 01:14:04

oeni4711
Member
Registered: 2013-11-21
Posts: 20

Re: TTG CE3 and PHP 7(.2)

In markdown.php I changed two lines:

41: @define( 'MARKDOWN_PARSER_CLASS',  'Markdown_Parser_Class' );
191: class Markdown_Parser_Class {

This removed the deprecated warning.

Unfortunately I still get the menu error.

And a newly created album is created partly (I see directory and some files but not gallery.xml in it.
When I try to go to album from LR I get a message that album is not created yet.
When accessing it online I get a blank page with "!file_exists".
http://fot-o-box.de/galerie/20181109-pme/

What creates gallery.xml?

Offline

#5 2018-11-09 01:23:11

oeni4711
Member
Registered: 2013-11-21
Posts: 20

Re: TTG CE3 and PHP 7(.2)

PHP Warning:  Declaration of My_Walker_Nav_Menu::start_lvl(&$output, $depth) should be compatible with Walker_Nav_Menu::start_lvl(&$output, $depth = 0, $args = Array) in /is/htdocs/wp1033049_1IEN2VSLAU/fot-o-box/wp/wp-content/themes/theme-v3/functions.php on line 284

preg_split(): Empty regular expression in /is/htdocs/wp1033049_1IEN2VSLAU/fot-o-box/wp/galerie/resources/php/markdown.php on line 1176

Offline

#6 2018-11-09 01:31:16

oeni4711
Member
Registered: 2013-11-21
Posts: 20

Re: TTG CE3 and PHP 7(.2)

rod barbee wrote:

In the long run, updating your site to Backlight is the best option.

Is that the best procedure to follow or any other tip? Does it work for CE3 as well?
http://ttg-tips-and-tricks.barbeephoto. … backlight/

Offline

#7 2018-11-09 01:33:06

Daniel Leu
Moderator
Registered: 2012-10-11
Posts: 1,061
Website

Re: TTG CE3 and PHP 7(.2)

If you can't revert back to a lower php version, then I might move ahead to migrate to Backlight 2.  Your site looks rather straightforward so that shouldn't be too difficult.

Backlight 2 can directly migrate CE4 based publisher created albums. I don't think upgrading from CE3 is supported. But CE4 can upgrade a CE3 album to CE4.

I would buy Backlight 2 and then send Matt an email and asking him for a copy of CE4 so you can upgrade your albums from CE3. That's all you do with CE4. Afterwards, you can upgrade this CE4 album to Backlight 2 and your album structure and photos are ready.


Daniel Leu | Photography   
DanielLeu.com

Offline

#8 2018-11-09 22:24:08

markharris
Member
From: Uppsala, Sweden
Registered: 2013-01-21
Posts: 42
Website

Re: TTG CE3 and PHP 7(.2)

I have the same problem, with hundreds of legacy galleries using CE4, many of them standalone, so hard to even find them.
So if anyone has a good code fix, I (and presumably many others) would be super grateful.

Offline

#9 2018-11-10 00:25:53

Daniel Leu
Moderator
Registered: 2012-10-11
Posts: 1,061
Website

Re: TTG CE3 and PHP 7(.2)

markharris wrote:

I have the same problem, with hundreds of legacy galleries using CE4, many of them standalone, so hard to even find them.
So if anyone has a good code fix, I (and presumably many others) would be super grateful.

This problem is related to CE3. Please open a new ticket if you have a problem with CE4.


Daniel Leu | Photography   
DanielLeu.com

Offline

#10 2018-11-10 04:05:50

oeni4711
Member
Registered: 2013-11-21
Posts: 20

Re: TTG CE3 and PHP 7(.2)

ERROR: count(): Parameter must be an array or an object that implements Countable
occurs in publisher/api/lib/AlbumVO.php(141):
for ($i = 0; $i < count($xmlArray['images']['image']); $i++) {

Changed it to this and album is created and photos can be published:

            // We don't want to keep this value
                        if ($xmlArray['images']['image'] == 1) {
                for ($i = 0; $i < count($xmlArray['images']['image']); $i++) {
                    unset($xmlArray['images']['image'][$i]['old_filename']);
                }
                        }

Last edited by oeni4711 (2018-11-10 04:18:46)

Offline

#11 2018-11-10 04:35:09

oeni4711
Member
Registered: 2013-11-21
Posts: 20

Re: TTG CE3 and PHP 7(.2)

And in theme's function PHP I had to change line 280

function start_lvl(&$output, $depth = 0) {

to this

function start_lvl(&$output, $depth = 0, $args = array()) {

Offline

#12 2018-11-10 04:52:38

oeni4711
Member
Registered: 2013-11-21
Posts: 20

Re: TTG CE3 and PHP 7(.2)

Ok, not corrected all errors yet but those prevented publisher and site to work ;-)

Offline

#13 2018-11-10 05:10:32

Daniel Leu
Moderator
Registered: 2012-10-11
Posts: 1,061
Website

Re: TTG CE3 and PHP 7(.2)

Just wondering... wouldn't it be easier just to move on to Backlight 2?


Daniel Leu | Photography   
DanielLeu.com

Offline

#14 2018-11-10 16:06:32

oeni4711
Member
Registered: 2013-11-21
Posts: 20

Re: TTG CE3 and PHP 7(.2)

Daniel Leu wrote:

Just wondering... wouldn't it be easier just to move on to Backlight 2?

Well, maybe not easier as I have two shows this weekend (one yesterday and one today) and clients requested/ordered online galleries. I don't think I can manage a move to whatever in parallel. Even for Backlight2 as my site is Wordpress with CE3 Theme for Wordpress and Publisher ;-)

Offline

Board footer

Powered by FluxBB