From: Yousong Zhou Date: Mon, 7 May 2018 14:07:15 +0000 (+0800) Subject: luci-app-commands: fix link generation X-Git-Url: https://git.librecmc.org/?a=commitdiff_plain;h=e4f77ace8b4fe9fd4c5d73e604eb1b8c6b480ed8;p=oweals%2Fluci.git luci-app-commands: fix link generation Fixes openwrt/luci##824 Signed-off-by: Yousong Zhou --- diff --git a/applications/luci-app-commands/luasrc/view/commands.htm b/applications/luci-app-commands/luasrc/view/commands.htm index 3b361558e..4285f25cb 100644 --- a/applications/luci-app-commands/luasrc/view/commands.htm +++ b/applications/luci-app-commands/luasrc/view/commands.htm @@ -108,9 +108,7 @@ if (legend && output) { - var prefix = location.protocol + '//' + location.hostname + - (location.port ? ':' + location.port : '') + - location.pathname.split(';')[0] + 'command/'; + var prefix = location.protocol + '//' + location.host + '<%=url('command')%>/'; var suffix = (args ? '/' + args : ''); var link = prefix + id + suffix;