Heyuri / kokonotsuba

Heyuri's BBS software
Other
19 stars 12 forks source link

PHP7.2-PHP8.x #63

Closed satopian closed 9 months ago

satopian commented 9 months ago

The deletion process performed by each has been replaced with foreach.

https://www.php.net/manual/en/function.each.php

This function has been DEPRECATED as of PHP 7.2.0, and REMOVED as of PHP 8.0.0. Relying on this function is highly discouraged.

https://www.php.net/manual/en/migration70.deprecated.php

PHP 4 style constructors (methods that have the same name as the class they are defined in) are deprecated, and will be removed in the future. PHP 7 will emit E_DEPRECATED if a PHP 4 constructor is the only constructor defined within a class. Classes that implement a __construct() method are unaffected.

https://www.php.net/manual/en/migration74.deprecated.php

Array and string offset access using curly braces The array and string offset access syntax using curly braces is deprecated. Use $var[$idx] instead of $var{$idx}.

https://www.php.net/manual/ja/function.get-magic-quotes-gpc.php get_magic_quotes_gpc() always returns False and the script will not work if this function exists in PHP8.x.

With the changes made so far, we confirmed in the XAMPP local environment that it works from PHP7.2 to PHP8.3.

The PHP8.x compatible version that we announced last time is $upfile=""; $upfile_path=""; $upfile_name=""; $upfile_status=""; was included, but not this time. I hope that even after I've made these changes, the script will continue to work correctly.