• package: tis-php
  • name: PHP
  • version: 8.4.6-13
  • categories: Development,System and network
  • maintainer: WAPT Team,Tranquil IT,Jimmy PELÉ, Gaëtan SEGAT
  • editor: The PHP Group
  • licence: PHP License
  • locale: all
  • target_os: windows
  • impacted_process: php,php-cgi,phpdbg,php-win
  • architecture: x86
  • signature_date:
  • size: 30.38 Mo
  • installed_size: 81.66 Mo
  • homepage : https://www.php.net/
  • depends:

package           : tis-php
version           : 8.4.6-13
architecture      : x86
section           : base
priority          : optional
name              : PHP
categories        : Development,System and network
maintainer        : WAPT Team,Tranquil IT,Jimmy PELÉ, Gaëtan SEGAT
description       : PHP (Hypertext Preprocessor) is a popular general-purpose scripting language that is especially suited to web development
depends           : tis-vcredist
conflicts         : 
maturity          : PROD
locale            : all
target_os         : windows
min_wapt_version  : 2.0
sources           : https://www.php.net/downloads.php
installed_size    : 81661071
impacted_process  : php,php-cgi,phpdbg,php-win
description_fr    : PHP (Hypertext Preprocessor) est un langage de programmation libre, principalement utilisé pour produire des pages Web
description_pl    : PHP (Hypertext Preprocessor) jest popularnym językiem skryptowym ogólnego przeznaczenia, który szczególnie nadaje się do tworzenia stron internetowych
description_de    : PHP (Hypertext Preprocessor) ist eine beliebte Allzweck-Skriptsprache, die sich besonders für die Webentwicklung eignet
description_es    : PHP (Hypertext Preprocessor) es un popular lenguaje de scripting de propósito general que es especialmente adecuado para el desarrollo web
description_pt    : PHP (Hypertext Preprocessor) é uma linguagem de scripting popular de uso geral que é especialmente adequada ao desenvolvimento web
description_it    : PHP (Hypertext Preprocessor) è un popolare linguaggio di scripting di uso generale, particolarmente adatto allo sviluppo web
description_nl    : PHP (Hypertext Preprocessor) is een populaire scripttaal voor algemeen gebruik die bijzonder geschikt is voor webontwikkeling
description_ru    : PHP (Hypertext Preprocessor) - это популярный язык сценариев общего назначения, который особенно подходит для разработки веб-сайтов
audit_schedule    : 
editor            : The PHP Group
keywords          : php,hypertext,preprocessor
licence           : PHP License
homepage          : https://www.php.net/
package_uuid      : 6ce6d5cc-5b6c-401e-ad8a-d7f0d8d944fe
valid_from        : 
valid_until       : 
forced_install_on : 
changelog         : https://www.php.net/ChangeLog-8.php
min_os_version    : 
max_os_version    : 
icon_sha256sum    : 2be60a2628fdda01aa7b610f0efd8e317abbdf744fb5a1b474194086d1bdebf5
signer            : Tranquil IT
signer_fingerprint: 8c5127a75392be9cc9afd0dbae1222a673072c308c14d88ab246e23832e8c6bb
signature_date    : 2025-04-16T08:21:22.000000
signed_attributes : package,version,architecture,section,priority,name,categories,maintainer,description,depends,conflicts,maturity,locale,target_os,min_wapt_version,sources,installed_size,impacted_process,description_fr,description_pl,description_de,description_es,description_pt,description_it,description_nl,description_ru,audit_schedule,editor,keywords,licence,homepage,package_uuid,valid_from,valid_until,forced_install_on,changelog,min_os_version,max_os_version,icon_sha256sum,signer,signer_fingerprint,signature_date,signed_attributes
signature         : jDg2Fgog4kmgDVXNwmF0qBauwRFBRABK+IlFIeQh60AEOnIJjK41aP3JUG+HuF8eocihfICkRyLytxzkFOtA3Glgbog+UQqTARgNx+Ax18MAS7Y31cxpn7/vUL1fjOBpEqMiJgyGXRq5Js/uG35FwnIzcDWdF0y4yJE9BSsS/C3Op7si+Gyr40QXhuiPbCbu5b55lytNtgM3HF33UEtNxUVdF+NYcczrt5Nr/+voNKI0iN3bT5/ej5pN6cqUPIgBDdBr0V+sbitXxh7wYL09lYaoK5Agm25nA5ybVxLXfjWFqLuD56V3MoSvCbsZauwBSeBtt23Ao3w9VjJjazx2mA==

# -*- coding: utf-8 -*-
from setuphelpers import *

app_name = "PHP"
app_dir = makepath(programfiles, app_name)
app_path = makepath(app_dir, "php.exe")
icon_path = app_path
audit_version_number = False


def get_installed_version(uninstallkey):
    for soft in installed_softwares(uninstallkey=uninstallkey):
        return soft.get("version", None)
    return None


def install():
    # Declaring local variables
    package_version = control.get_software_version()
    installed_version = get_installed_version(app_name)
    bin_name = glob.glob("php-*.zip")[0]

    # Installing software
    print("Installing: %s" % app_name)
    if installed_version is None or Version(installed_version) < Version(package_version) or force:
        killalltasks(control.get_impacted_process_list())
        if isdir(app_dir):
            remove_tree(app_dir)
        mkdirs(app_dir)
        print("Extracting: %s to: %s" % (bin_name, app_dir))
        unzip(bin_name, target=app_dir)
        add_to_system_path(app_dir)

        # Creating shortcuts
        if not params.get("remove_desktop_shortcut"):
            create_desktop_shortcut(app_name, app_path, icon=icon_path)
            create_programs_menu_shortcut(app_name, app_path, icon=icon_path)

        # Adding software to "list-registry"
        print("Registering: %s to Windows Registry" % app_name)
        register_windows_uninstall(control, win64app=iswin64())
        register_uninstall(app_name, win64app=iswin64(), icon=icon_path)
    else:
        print("%s is already installed and up-to-date" % app_name)


def audit():
    # Declaring local variables
    package_version = control.get_software_version()
    installed_version = get_installed_version(app_name)

    # Auditing software
    print("Auditing: %s" % control.package)
    if installed_version is None:
        print("%s is not installed" % app_name)
        return "ERROR"
    elif Version(installed_version) != Version(package_version) and audit_version_number:
        print("%s is installed in version (%s) instead of (%s)" % (app_name, installed_version, package_version))
        return "WARNING"
    else:
        print("%s (%s) is installed" % (app_name, installed_version))
        return "OK"


def uninstall():
    # Uninstalling software
    killalltasks(control.get_impacted_process_list())
    if isdir(app_dir):
        remove_tree(app_dir)
    unregister_uninstall(app_name, win64app=iswin64())
    remove_from_system_path(app_dir)

    # Removing shortcuts
    remove_desktop_shortcut(app_name)
    remove_programs_menu_shortcut(app_name)

# -*- coding: utf-8 -*-
from setuphelpers import *


def update_package():
    # Declaring local variables
    package_updated = False
    proxies = get_proxies()
    if not proxies:
        proxies = get_proxies_from_wapt_console()
    app_name = control.name
    url = "https://windows.php.net/download"
    arch_dict = {"x64": "-Win32-vs17-x64", "x86": "-Win32-vs17-x86"}

    # Getting latest version from official sources
    print("URL used is: %s" % url)
    for bs_search in bs_find_all(url, "a", proxies=proxies):
        if bs_search.text == "Zip":
            if arch_dict[control.architecture] in bs_search["href"] and not "-nts-" in bs_search["href"]:
                download_url = "https://windows.php.net" + bs_search["href"]
                latest_bin = bs_search["href"].split("/")[-1]
                version = latest_bin.split("-")[1]
                break

    # Downloading latest binaries
    print("Latest %s version is: %s" % (app_name, version))
    print("Download URL is: %s" % download_url)
    if not isfile(latest_bin):
        print("Downloading: %s" % latest_bin)
        wget(download_url, latest_bin, proxies=proxies)
    else:
        print("Binary is present: %s" % latest_bin)

    # Changing version of the package
    if Version(version) > Version(control.get_software_version()):
        print("Software version updated (from: %s to: %s)" % (control.get_software_version(), Version(version)))
        package_updated = True
    else:
        print("Software version up-to-date (%s)" % Version(version))
    control.set_software_version(version)
    control.save_control_to_wapt()

    # Deleting outdated binaries
    remove_outdated_binaries(version, "zip")

    # Validating or not update-package-sources
    return package_updated

38d056ab130f7bf7c481c12636a4e9959de36561d3dfcbe54c6e3571bc0c1dc3 : WAPT/certificate.crt
fe100beb2700afb6db94ddccae01735000b0b2f36f6f68b884bde7e442fbaf9d : WAPT/changelog.txt
221ba8e5248464c568a8e7933ac4f9041466ea8ff848dd566a0f75c5fe1ef636 : WAPT/control
2be60a2628fdda01aa7b610f0efd8e317abbdf744fb5a1b474194086d1bdebf5 : WAPT/icon.png
7a9469aa2ebd88753ea45420e6257035abe6c1b24e943d34b71a7970b9a6dfc2 : luti.json
1d7ecf3b63c84ae2717bc9f6449a6907b35697f5ec621225f88af88721eca321 : php-8.4.6-Win32-vs17-x86.zip
16217ee592231d488813df3c4410cec317a861ce0eada2fa8041722154a59a7a : setup.py
d9e8d9f9caf46caf620116154957ecd2637418030dde6252b445978908caa14b : update_package.py

https://www.php.net/ChangeLog-8.php
8.1.10-13
portable install reworked, now register the app in registry
package globally improved