Edward's Tech Site

this site made with Next.js 13, see the code

FORAY: Nov 21, 2020 - PHP
Upgrade XAMPP from PHP 7.2 to PHP 7.4
  • PHP 7.4 was released in November 2019
  • current status
    • my PHP is currently: php --version = PHP 7.2.2 (cli)
    • at a2hosting: php --version = PHP 7.2.34 (cli)
  • local test to make sure 7.4 feature does not work:
  • upgrade XAMPP from 7.2 to 7.4
    • uninstall XAMPP
      • copy important files:
        • C:\xampp\apache\conf\httpd.conf
          • mainly this is what you need from it:
            • #DocumentRoot "C:/xampp/htdocs"
              DocumentRoot "C:/edward/webs"
               
              #<Directory "C:/xampp/htdocs">
              <Directory "C:/edward/webs">
        • C:\xampp\php\php.ini
          • mainly this is what you need from it:
            • extension=bz2
              extension=curl
              extension=fileinfo
              extension=gd2
              extension=gettext
              ;extension=gmp
              ;extension=intl
              ;extension=imap
              ;extension=interbase
              ;extension=ldap
              extension=mbstring
              extension=exif ; Must be after mbstring as it depends on it
              extension=mysqli
              ;extension=oci8_12c ; Use with Oracle Database 12c Instant Client
              extension=openssl
              ;extension=pdo_firebird
              extension=pdo_mysql
              ;extension=pdo_oci
              ;extension=pdo_odbc
              ;extension=pdo_pgsql
              extension=pdo_sqlite
              ;extension=pgsql
              ;extension=shmop
      • searched for "uninstall xampp" and ran it
        • "Are you sure you want to uninstall XAMPP and all of its modules?"
        • "Uninstallation completed."
        • deleted c:\xampp directory (some files were left in there that I created)
    • install XAMPP with PHP 7.4
      • ../download.htmlhttps://www.apachefriends.org/download.html
      • seems to have: containing MariaDB, PHP, and Perl (not MySQL now)
        • "Since XAMPP 5.5.30 and 5.6.14, XAMPP ships MariaDB instead of MySQL. The commands and tools are the same for both."
      • downloading: 7.4.12 / PHP 7.4.12
      • executing: xampp-windows-x64-7.4.12-0-VC15-installer.exe
    • setup and test
      • start Apache
      • but ../runhttp://localhost/run not found
        • made these changes in httpd.conf
          • #DocumentRoot "C:/xampp/htdocs"
            DocumentRoot "C:/edward/webs"
            #<Directory "C:/xampp/htdocs">
            <Directory "C:/edward/webs">
      • restarted Apache and it works
      • testing: ../learntrackerhttp://localhost/learntracker
        • extension=pdo_sqlite was already uncommented in php.ini
      • got these errors: Deprecated: Array and string offset access syntax with curly braces is deprecated in C:\edward\webs\learntracker\thirdParty\markdown\Markdown.php on line 1675
        • had to go through each and change e.g. {0} to {1}
  • test PHP 7.4 locally