View Issue Details

IDProjectCategoryView StatusLast Update
0020501mantisbtcode cleanuppublic2016-08-15 09:02
ReporteratrolAssigned Todregad 
PrioritynormalSeverityminorReproducibilityalways
Status closedResolutionfixed 
Product Version1.2.19 
Target Version1.2.20Fixed in Version1.2.20 
Summary0020501: Installer throws warning in PHP 7 environment
Description

Environment: Windows 10, XAMPP, PHP 7.0.1, FF 43

Running admin/install.php throws warning:

Deprecated: Methods with the same name as their class will not be constructors
in a future version of PHP; UserPreferences has a deprecated constructor in
C:\xamppphp7\htdocs\mantisbt\core\user_pref_api.php on line 48

See http://php.net/manual/en/migration70.deprecated.php#migration70.deprecated.php4-constructors

Tagsphp7

Relationships

related to 0020500 closedatrol Installation fails in PHP 7 environment 
related to 0020864 closeddregad "user_pref_get_language()" not defined 
child of 0020499 closeddregad Compatibility with PHP 7 

Activities

dregad

dregad

2016-01-11 07:00

developer   ~0052289

Last edited: 2016-01-11 07:00

View 2 revisions

I replaced PHP4-style constructors by __construct() in

  • user_pref_api (UserPreferences class),
  • graphviz_api.php (Graph class) and
  • MantisGraph plugin (Period class)

Also, backported to 1.2.x since we require PHP5 it doesn't hurt.

atrol

atrol

2016-01-11 07:15

developer   ~0052291

Also, backported to 1.2.x since we require PHP5 it doesn't hurt.

Not sure if it makes sense to touch 1.2.x in terms of PHP7.
Seems there is more work needed, e.g. 0020484

Maybe time to activate travis PHP7 in master?

dregad

dregad

2016-01-11 07:56

developer   ~0052292

Not sure if it makes sense to touch 1.2.x in terms of PHP7.

Maybe not, but as I said, it's a simple and straightforward change so it doesn't hurt.

Maybe time to activate travis PHP7 in master?

Will do.

Related Changesets

MantisBT: master baae433f

2016-01-11 06:49:13

dregad

Details Diff
PHP7: Remove old-style constructors

PHP4-style constructors are deprecated in PHP7.

Fixes 0020501
mod - core/graphviz_api.php Diff File
mod - core/user_pref_api.php Diff File
mod - plugins/MantisGraph/core/Period.php Diff File

MantisBT: master-1.2.x a9731e94

2016-01-11 06:49:13

dregad

Details Diff
PHP7: Remove old-style constructors

PHP4-style constructors are deprecated in PHP7.

Fixes 0020501
mod - core/graphviz_api.php Diff File
mod - core/user_pref_api.php Diff File
mod - plugins/MantisGraph/core/Period.php Diff File

MantisBT: master db98d830

2016-05-01 04:59:08

dregad

Details Diff
PHP7: Remove old-style constructors

One function was omitted from baae433f220fe8b0bed41e0ffb4c46942729a142.

Fixes 0020501
mod - core/graphviz_api.php Diff File

MantisBT: master-1.2.x 6b9bf08b

2016-05-01 04:59:08

dregad

Details Diff
PHP7: Remove old-style constructors

One function was omitted from a9731e9468f3112bde652326310bd3fcf5086a29.

Fixes 0020501
mod - core/graphviz_api.php Diff File

Issue History

Date Modified Username Field Change
2016-01-11 02:43 atrol New Issue
2016-01-11 02:43 atrol Relationship added child of 0020499
2016-01-11 04:56 atrol Description Updated View Revisions
2016-01-11 06:57 dregad Changeset attached => MantisBT master baae433f
2016-01-11 06:57 dregad Assigned To => dregad
2016-01-11 06:57 dregad Status new => resolved
2016-01-11 06:57 dregad Resolution open => fixed
2016-01-11 06:57 dregad Fixed in Version => 1.3.0-rc.2
2016-01-11 06:57 dregad Changeset attached => MantisBT master-1.2.x a9731e94
2016-01-11 07:00 dregad Target Version => 1.3.0-rc.2
2016-01-11 07:00 dregad Note Added: 0052289
2016-01-11 07:00 dregad Note Edited: 0052289 View Revisions
2016-01-11 07:15 atrol Note Added: 0052291
2016-01-11 07:15 atrol Product Version 1.3.0-rc.2 => 1.2.19
2016-01-11 07:15 atrol Fixed in Version 1.3.0-rc.2 => 1.2.20
2016-01-11 07:15 atrol Target Version 1.3.0-rc.2 => 1.2.20
2016-01-11 07:56 dregad Note Added: 0052292
2016-01-14 02:07 atrol Relationship added related to 0020500
2016-04-30 13:18 atrol Relationship added related to 0020864
2016-05-01 04:39 dregad Tag Attached: php7
2016-05-01 05:17 dregad Changeset attached => MantisBT master db98d830
2016-05-01 05:17 dregad Changeset attached => MantisBT master-1.2.x 6b9bf08b
2016-08-15 09:02 dregad Status resolved => closed