timeline_ctrl 123 syntax error
Brought to you by:
canajun2eh,
yalnifj
SVN 7348 with PHP 7.4.28-1+deb11u1
After calling /timeline.php?ged=myged.ged&pids[]=Innnn
I get:
Parse error: syntax error, unexpected ';' in /path/includes/controllers/timeline_ctrl.php on line 123
Line looks quite correct, I tried to look in files containing MinDate()
function under /includes/
but can't find anything wrong in class_date.php...
Where does this error get into this place?
Try replacing line 122 of /includes/controllers/timeline_ctrl.php with the following:
if (is_object($date)) {
fixed in SVN 7349
It was the first thing I tried because saw unclosed parentheses but the problem is probably elsewhere because after this correction I get:
Fatal error: Uncaught Error: Call to a member function convert_to_cal() on null in /var/www/phpGedView/includes/controllers/timeline_ctrl.php:124 Stack trace: #0 /var/www/phpGedView/timeline.php(36): TimelineControllerRoot->init() #1 {main} thrown in /var/www/phpGedView/includes/controllers/timeline_ctrl.php on line 124
P.S. My data comes from ged produced by Gramps (and imported after making changes).
Don't know what values PGV stores in case of incomplete dates knowledge but mine is:
select count() from pgvdates where dgid = 'I0006' and dmonth = '';
=17 (and these are emptystr not NULLs)
But don't know if it matters...
Diff:
Try the attached file to replace /includes/controllers/timeline_ctrl.php .
The problem is caused by "improvements" to PHP 7.4.
works like a charm - BIG thx
Fixed once and for all in SVN 7350.