You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
With PHP 8 missing LAN constant will break your site so this is really important.
I understand the need to clean LAN files but there should be some safe solution not to break the site doing this.
With shortcodes there are legacy_shortcodes, with template there is {LAN} shortcode to manage this.
But there are many places in core or custom plugins that are using constant directly and if you use updated LANs files for older core, deleted LANs end in fatal error.
Could you add something like legacy_language file with the list of deleted LANs? Maybe add a preference/config constant to load legacy LANs?
your
Proposed Solution
Load special file for deleted LANs if it is set by site admin (not needed always)
There are 2 options:
add deleted LAN there (as was originally defined)
OR
check if deleted LAN exists and if not, add a definition by a constant that is its replacement.
I prefer last option because it says translators what is replacement and you can delete that line and comment from lan file.
Alternatives
.
Additional Context
Example:
deleted LAN_ERROR_9 was replaced with LAN_ERROR_3
but there could be plugins that are using LAN_ERROR_9 and this will break them in PHP 8
Thanks
The text was updated successfully, but these errors were encountered:
Motivation
With PHP 8 missing LAN constant will break your site so this is really important.
I understand the need to clean LAN files but there should be some safe solution not to break the site doing this.
With shortcodes there are legacy_shortcodes, with template there is {LAN} shortcode to manage this.
But there are many places in core or custom plugins that are using constant directly and if you use updated LANs files for older core, deleted LANs end in fatal error.
Could you add something like legacy_language file with the list of deleted LANs? Maybe add a preference/config constant to load legacy LANs?
your
Proposed Solution
Load special file for deleted LANs if it is set by site admin (not needed always)
There are 2 options:
OR
I prefer last option because it says translators what is replacement and you can delete that line and comment from lan file.
Alternatives
.
Additional Context
Example:
deleted LAN_ERROR_9 was replaced with LAN_ERROR_3
but there could be plugins that are using LAN_ERROR_9 and this will break them in PHP 8
Thanks
The text was updated successfully, but these errors were encountered: