Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Reformat code to PSR2 and use short array syntax #5

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

simonschaufi
Copy link
Contributor

No code changes, just reformating and replacing array() with []

@roxblnfk
Copy link
Contributor

roxblnfk commented Jan 19, 2018

Square brackets require a php version >=5.4

@simonschaufi
Copy link
Contributor Author

Yes I know but these old php versions are not supported anymore.

tbs_class.php Outdated
@@ -15,8 +14,9 @@
*/

// Check PHP version
if (version_compare(PHP_VERSION,'5.0')<0) echo '<br><b>TinyButStrong Error</b> (PHP Version Check) : Your PHP version is '.PHP_VERSION.' while TinyButStrong needs PHP version 5.0 or higher. You should try with TinyButStrong Edition for PHP 4.';
/* COMPAT#1 */
if (version_compare(PHP_VERSION, '5.0') < 0) {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Compare with 5.4

tbs_class.php Outdated
if (version_compare(PHP_VERSION,'5.0')<0) echo '<br><b>TinyButStrong Error</b> (PHP Version Check) : Your PHP version is '.PHP_VERSION.' while TinyButStrong needs PHP version 5.0 or higher. You should try with TinyButStrong Edition for PHP 4.';
/* COMPAT#1 */
if (version_compare(PHP_VERSION, '5.0') < 0) {
echo '<br><b>TinyButStrong Error</b> (PHP Version Check) : Your PHP version is ' . PHP_VERSION . ' while TinyButStrong needs PHP version 5.0 or higher. You should try with TinyButStrong Edition for PHP 4.';
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

needs 5.4 or higher

@Skrol29
Copy link
Owner

Skrol29 commented Feb 13, 2018

The problem is PHP 5.3 is 20% used of the PHP 5 versions, just quite as much as PHP 5.4
PHP 7 is 12% of all PHP versions.
https://w3techs.com/technologies/history_details/pl-php/5

@simonschaufi
Copy link
Contributor Author

simonschaufi commented Feb 13, 2018

Well, one day, sooner or later you have to say: From now on I won't support totally outdated php versions any more (and php 5.3 is totally outdated). Officially supported is just php5.6 at the moment. Of course after merging this, the second or even the first version number should be raised up as it will break existing systems if they try to upgrade and still have 5.3 running. So imho a new major version should be released.

@simonschaufi
Copy link
Contributor Author

@Skrol29 Are you still interested in this PR? I just found it again while browsing through my open PRs. Should I clean this up so it can be merged?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants