?
avatar mbabker
mbabker
21 Feb 2017

Similar to how we've already restructured the install app, the administrator/index.php and index.php files should be restructured in a way that allows those files to remain PHP 5.2 friendly while not impeding us using PHP 5.3+ features (like namespaced classes).

avatar mbabker mbabker - open - 21 Feb 2017
avatar joomla-cms-bot joomla-cms-bot - change - 21 Feb 2017
Labels Added: ?
avatar joomla-cms-bot joomla-cms-bot - labeled - 21 Feb 2017
avatar Spudley
Spudley - comment - 24 Feb 2017

Why would we need those files to "remain PHP 5.2 friendly", given that the very first thing those files do is check for PHP 5.3+?

avatar zero-24
zero-24 - comment - 24 Feb 2017

The problem is if they are not PHP 5.2 friendly they can't be execued by PHP 5.2 so the check is not execued too. ?

avatar mbabker
mbabker - comment - 24 Feb 2017

Exactly. We still want to show a "your platform isn't supported" message to older PHP versions without the files being written in a way that makes them not parseable on older versions. So either everything in the index.php file has to remain in the global namespace or we give everyone who's on PHP 5.2 (or up to 5.5.8 depending on how the files are written and what language features are used) a PHP fatal because of the invalid syntax for those versions.

Basically, the index.php files should be simplified to this - https://github.com/joomla/joomla-cms/blob/4.0-dev/installation/index.php

avatar zero-24
zero-24 - comment - 24 Feb 2017

@mbabker please review: #14236

avatar jeckodevelopment jeckodevelopment - change - 26 Feb 2017
Status New Closed
Closed_Date 0000-00-00 00:00:00 2017-02-26 11:23:47
Closed_By jeckodevelopment
avatar jeckodevelopment jeckodevelopment - close - 26 Feb 2017

Add a Comment

Login with GitHub to post a comment