What's new in PHP 8.3+
Minimum PHP version updated
The application now requires PHP 8.3 as the minimum version.
Database updates
BIGINT columns
All columns containing crmids are now BIGINT (for new installations). When creating columns that store crmid, always use BIGINT (or I8 when using adodb datadict).
TINYINT columns
All columns containing only boolean integers (e.g., 0/1 for checkbox fields uitype 56, deleted=0/1, or various status columns with only small ints) are now TINYINT (or I1 when using adodb datadict).
Licence tag requirement
A new SPDX license tag is now mandatory in all vtenext core files (php, js and tpl) that are not external libraries.
/*************************************
* SPDX-FileCopyrightText: 2009-present Vtenext S.r.l. Società Benefit
* SPDX-License-Identifier: LicenseRef-vtenext-business-license
************************************/
New libraries
All third party libraries now must be imported via composer (living in the /vendor/ folder), or placed in the /vendor-extra/ folder. Libraries in vendor-extra are automatically included in the class path.
Important note
Whenever a new library is added, either via composer or manually, the following command must be executed to refresh the classmap:
composer dump-autoload -oLibraries updated
| Library | Previous version | New version |
|---|---|---|
phpmailer/phpmailer |
6.6.5 | 6.9.3 |
ezyang/htmlpurifier |
4.13.0 | 4.18.0 |
mpdf/mpdf |
8.0.12 | 8.2.5 |
league/iso3166 |
2.1.5 | 4.3.2 |
league/oauth2-client |
2.7.0 | 2.8.1 |
league/oauth2-google |
3.0.4 | 4.0.1 |
spomky-labs/otphp |
10.0.3 | 11.3.0 |
joypixels/emoji-toolkit |
6.6.0 | 9.0.1 |
phpoffice/phpspreadsheet |
1.8.2 | 4.1.0 |
phpseclib/phpseclib |
3.0.42 | 3.0.43 |
jaybizzle/crawler-detect |
1.3.0 | 1.3.4 |
hubspot/hubspot-php |
2.0 | 5.3.0 |
slince/shopify-api-php |
2.5 | 3.1.0 |
zendesk/zendesk_api_client_php |
2.29 | 4.1.0 |
lesstif/php-jira-rest-client |
1.41 | 5.9.0 |
Libraries added
web-token/jwt-library4.0.4php-amqplib/php-amqplib3.7.3econea/nusoap0.9.18dragonmantank/cron-expression3.4.0qualityunit/tnef-decoder1.2.9sabre/vobject4.5.6flipboxdigital/oauth2-hubspot1.0.1stevenmaguire/oauth2-salesforce2.0.1stevenmaguire/oauth2-zendesk2.1.0automattic/woocommerce3.1.0monolog(replaces log4php) 3.8.1
Libraries moved to vendor
The following libraries have been moved from various locations to /vendor/ or /vendor-extra/:
include/nusoap→ moved to vendormodules/Settings/ProcessMaker/thirdparty/cron-expression→ moved to vendormodules/PDFMaker/classes/simple_html_dom.php→ moved to vendor-extrainclude/magpierss→ moved to vendor-extramodules/Morphsuit/utils/RSA→ replaced with phpseclib in vendormodules/Newsletter/bounce_driver.class.php→ moved to vendor-extramodules/Messages/src/attachment_tnef→ moved to vendormodules/Messages/src/Squirrelmail.php→ moved to vendor-extrasmartoptimizer→ moved to vendor-extra (updated minifier, added brotli and zstandard support)portal/nusoap→ moved to vendorportal/include/htmlpurifier→moved to vendorremovedinclude/pChart→ patched and moved to vendor-extrainclude/freetag→ fixed and moved to vendor-extramodules/VteSync/vendor→ moved to main vendormodules/VteSync/VteSyncLib/src/Connector/Jira/vendor→ moved to main vendor
Removed libraries
log4php-Being replacedReplaced with monologvtlib/SimplePie- No longer usedinclude/antlr- Not working, grammar unknown and never usedmodules/SDK/examples/intellisense- Removedmodules/Calendar/iCal/ical-parser-class.php- Not usedmodules/Calendar/iCal/iCalendar_*.php(Bennu) - Replaced with sabre/vobjectmodules/Calendar/iCal/iCalcreator- Replaced with sabre/vobjectinclude/Zend- Simplifiedgdpr/include/vtwsclib/lib/Zend- Removedportal/include/Zend- Removedvidelalvaro/php-amqplib- Replaced with php-amqplib/php-amqplibweb-token/jwt-easy,web-token/jwt-key-mgmt,web-token/signature-pack- Replaced with web-token/jwt-library
New configuration files
All new custom configuration files (e.g., custom api token) must be placed in the /config folder. If some configuration is different from dev/prod environments, use the corresponding config file in /config/.
config.$envType.php: Overrides of PHP configuration and global variables for a specific environment typephpstan/*: Configuration to use when running phpstansmarty/*: Configuration directory for Smarty library
logging.php: Configuration for the legacy logs (old log4php)
request.config.php: See Configuration - RequestHandler
New Config Variables
The following global config variables have been added to config.inc.php:
$enableLegacyLogs
Activate the legacy logs (the old log4php), which logs a lot of stuff in logs/vtenext.log. The usefulness of this log is not certain. Configuration of this log is in /config/logging.php.
$envType
Specify the environment type. Possible values:
"prod"(default)"preprod""dev""debug"
Each level activates more error messages. The default configuration is in config.inc.php, variable $php_config, overridden by the specific /config/config.$envType.php file.
$php_config
Used to specify the default PHP configuration used by $envType.
New Functions and Methods
CRMEntity Methodsmethods Update
update
The old retrieve_entity_info has been renamed to retrieve_html and retrieve_entity_info_no_html to retrieve. This is to make more explicit that there is a HTML conversion going on. The old functions are deprecated, but still working.
CRMEntity::retrieve_html(): Retrieves entity with HTML conversionCRMEntity::retrieve(): Retrieves entity without HTML conversion
Translation Aliases
New convenient aliases for translation functions:
trans(): Alias forgetTranslatedString()trans_app(): Alias forgetTranslatedString($str, "APP_STRINGS")trans_js(): Alias forgetTranslatedString($str, "ALERT_ARR")
New Databasedatabase Queryquery Methods
methods
New database query methods are available. For details, see: Database Best Practices
New Tools
tools/changeEnv.phpchange-env
Allows to easily change the $envType variable in config.inc.php and automatically execute scripts afterwards. Scripts to execute are located in plugins/envs/make.$env/*.
Important Filesfiles and Folders
folders
cache_local/
This folder should contain cache files to be stored on the same host as the webserver. It is useful in case of cluster deployment, where the cache/ folder is normally shared, but cache_local/ is only local.
plugins/envs/
Contains the scripts to be executed when changing the environment type (e.g., after cloning the prod in the dev host).
Deprecated Libraries
Check the current revision for the list of deprecated libraries and their deprecation reasons.
Removed Libraries
See ticket
TT-328904 for the complete list of removed libraries and their removal reasons.
Removed Config Variables
The following config variables have been removed:
$display_empty_home_blocks
Never used.
$php_max_execution_time
Misleading, since it was applied only in a few cases, and it was always 0, setting the limit to unlimited. Replaced by the $php_config and specific overrides when needed (e.g., Report export, PDF generation).
Removed Filesfiles and Folders
folders
modules/Dashboard
Removed this module, already deprecated and inactive.
PEAR.php
Used only by Dashboard and by obsolete libraries.
Image/*
Used only by Dashboard module.
include/db_backup
Not used anymore (and also a bad idea to make a full backup on admin logout).
Smarty/templates_c
Moved to cache_local/smarty to keep the number of writable folders limited.
plugins/erpconnectorDir
This folder was used in the past to perform one-way and one/two-way synchronizations with external systems. It has now been replaced by the DataImporterData Import tool (user manual).
GDPR portal update
The GDPR portal has been significantly updated with the following improvements:
- Migration of libraries to Composer for better dependency management
- API calls switched to vtenext RestClient
- Smarty templating engine upgraded to the latest version (^5.4)