From 938418d51fb84f4bfca6eb6acfe79a2fb227f1a4 Mon Sep 17 00:00:00 2001 From: Matteo Nastasi Date: Fri, 17 Apr 2020 07:32:55 +0200 Subject: [PATCH] assign myname js variable --- web/Obj/user.phh | 5 +++-- web/briskin5/index.php | 2 ++ web/index.php | 1 + 3 files changed, 6 insertions(+), 2 deletions(-) diff --git a/web/Obj/user.phh b/web/Obj/user.phh index d6a4395..d126176 100644 --- a/web/Obj/user.phh +++ b/web/Obj/user.phh @@ -605,8 +605,9 @@ class User { $sp = " "; } } - return (sprintf('$("myname").innerHTML = "%s";', $cl, - xcape($this->name,ENT_COMPAT,"UTF-8"))); + $myname = xcape($this->name,ENT_COMPAT,"UTF-8"); + return (sprintf('window.myname = "%s"; $("myname").innerHTML = "%s";', + $myname, $cl, $myname)); } /* INDEX_RD PORT */ diff --git a/web/briskin5/index.php b/web/briskin5/index.php index 68f6287..6071c73 100644 --- a/web/briskin5/index.php +++ b/web/briskin5/index.php @@ -79,6 +79,7 @@ function bin5_index_main($transp_type, $header, &$header_out, $addr, $get, $post