From 6db4ef75207011d8deeb15e5fc56378b227398d7 Mon Sep 17 00:00:00 2001 From: bergware Date: Mon, 3 Feb 2025 18:46:16 +0100 Subject: [PATCH] Add wlan to port selection --- emhttp/plugins/dynamix/DashStats.page | 3 ++- emhttp/plugins/dynamix/nchan/update_3 | 3 ++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/emhttp/plugins/dynamix/DashStats.page b/emhttp/plugins/dynamix/DashStats.page index 0f68cb030..8e46f29f8 100644 --- a/emhttp/plugins/dynamix/DashStats.page +++ b/emhttp/plugins/dynamix/DashStats.page @@ -145,7 +145,8 @@ $cpumodel = str_ireplace(["Processor","(C)","(R)","(TM)"],["","©","®", $cpumodel .= (strpos($cpumodel,'@')===false && !empty($cpu['Current Speed']) ? " @ {$cpu['Current Speed']}" : ""); $total = exec("awk '/^MemTotal/{print $2*1024}' /proc/meminfo"); -unset($ports); exec("ls /sys/class/net|grep -Po '^(lo|(bond|eth)\d+)$'",$ports); +unset($ports); exec("ls --indicator-style=none /sys/class/net|grep -Po '^(bond|eth|wlan)\d+$'",$ports); +$ports[] = 'lo'; $sizes = ['MB','GB','TB']; $memory_type = $ecc = ''; diff --git a/emhttp/plugins/dynamix/nchan/update_3 b/emhttp/plugins/dynamix/nchan/update_3 index a5ab73355..89db15da0 100755 --- a/emhttp/plugins/dynamix/nchan/update_3 +++ b/emhttp/plugins/dynamix/nchan/update_3 @@ -50,7 +50,8 @@ function update_translation($locale) { } function ports() { global $net; - exec("ls --indicator-style=none $net|grep -Po '^(lo|(bond|eth)\d+)$'",$ports); + exec("ls --indicator-style=none $net|grep -Po '^(bond|eth|wlan)\d+$'",$ports); + $ports[] = 'lo'; return $ports; }