From 3f1d428660458479eb6ea491751c915e25810a27 Mon Sep 17 00:00:00 2001 From: Cameron Date: Tue, 19 Apr 2022 11:09:58 -0700 Subject: [PATCH] Fixes #4755 - {LAN} shortcode - prioritize constants beginning with "LAN_" --- e107_core/shortcodes/single/lan.php | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/e107_core/shortcodes/single/lan.php b/e107_core/shortcodes/single/lan.php index 5f449f52b..be125fcc9 100644 --- a/e107_core/shortcodes/single/lan.php +++ b/e107_core/shortcodes/single/lan.php @@ -9,14 +9,15 @@ function lan_shortcode($parm = '') } $lan = trim($parm); - if(defined($lan)) - { - return constant($lan); - } - elseif(defined('LAN_'.$lan)) + + if(defined('LAN_'.$lan)) { return constant('LAN_'.$lan); } + elseif(defined($lan)) + { + return constant($lan); + } elseif(ADMIN) { return "".$parm ." is undefined"; // debug info