Guest User

Untitled

a guest
Jan 9th, 2022
38
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 8.56 KB | None | 0 0
  1. <%
  2. var login_err_msg = getenv("request/login_err_msg");
  3. var is_login_blocked = getenv("request/is_login_blocked");
  4. var login_monotonic_id = getenv("request/login_monotonic_id");
  5. var language = getenv("request/language");
  6. var langclass = getenv("request/langclass");
  7. var styleback = getenv("request/styleback");
  8. var head = "<!DOCTYPE html PUBLIC \"-\/\/W3C\/\/DTD XHTML 1.0 Transitional\/\/EN\"";
  9. var head1 = "\"http:\/\/www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd\">";
  10. var head_html = "<html xmlns=\"http:\/\/www.w3.org/1999/xhtml\">";
  11. =head + head1;
  12. =head_html;
  13. var upload_login_flag = getenv("UPLOAD_LOGIN");
  14. unsetenv("UPLOAD_LOGIN");
  15. %>
  16. <head>
  17. <META HTTP-EQUIV="pragma" CONTENT="no-cache">
  18. <META HTTP-EQUIV="Cache-Control" CONTENT="no-cache, must-revalidate">
  19. <meta http-equiv="X-UA-Compatible" content="IE=edge" />
  20. <meta http-equiv="Content-Type" content="text/html; charset=&?LANG;" />
  21. <title><%=getenv("WEBTitle");%></title>
  22. <LINK REL="stylesheet" HREF='<%=getenv("css_path_login");%>' TYPE="text/css" />
  23. <LINK REL="stylesheet" HREF="&?csslang;" TYPE="text/css" />
  24. <script>
  25. <%
  26. if (upload_login_flag == "1") {
  27. %>
  28. top.location.href = "/";
  29. <%
  30. }
  31. %>
  32. function getObj(id)
  33. {
  34. return(document.getElementById(id));
  35. }
  36. var SetTFlag = 0;
  37. var maxtime;
  38. var interval;
  39. var code;
  40. function setTime()
  41. {
  42. if(window.name>=60 || window.name<0 || window.name=="")
  43. {
  44. maxtime = Math.min(60, <%=getenv("errLoginTime");%> + 60 - <%=timestamp();%>);
  45. }
  46. else
  47. {
  48. maxtime = window.name;
  49. }
  50. if(maxtime>=0)
  51. {
  52. seconds = maxtime;
  53. getObj("time").innerHTML=seconds+"&?login005;";
  54. if (maxtime == 0)
  55. {
  56. setDisable();
  57. SetTFlag =0;
  58. window.name="";
  59. if(interval)
  60. {
  61. clearInterval(interval);
  62. interval = 0;
  63. }
  64. }
  65. else
  66. {
  67. --maxtime;
  68. SetTFlag = 1;
  69. window.name = maxtime;
  70. }
  71. }
  72. }
  73. function setinner(type)
  74. {
  75. if (SetTFlag ==0)
  76. {
  77. getObj("myLayer").style.visibility = type ;
  78. }
  79. }
  80. function Transfer_meaning(id,value)
  81. {
  82. getObj(id).value=value;
  83. }
  84. function ChangeLang()
  85. {
  86. var lang = "<%=language;%>";
  87. getObj("_lang").disabled = false;
  88. getObj("Frm_Username").disabled = true;
  89. getObj("Frm_Password").disabled = true;
  90. if(true != getObj("TestLang01").disabled)
  91. {
  92. if ("English" == lang)
  93. {
  94. getObj("_lang").value = "Portuguese";
  95. }
  96. else if ("Portuguese" == lang)
  97. {
  98. getObj("_lang").value = "English";
  99. }
  100. getObj("action").value = "setlang";
  101. getObj("Frm_Username").disabled = true;
  102. getObj("Frm_Password").disabled = true;
  103. getObj("LoginId").disabled = true;
  104. document.fLogin.submit();
  105. }
  106. }
  107. function focusUsername()
  108. {
  109. if (getObj("Frm_Username").disabled == false)
  110. {
  111. getObj("Frm_Username").focus();
  112. }
  113. createCode();
  114. }
  115. </script>
  116. </head>
  117. <%
  118. %>
  119. <body onload = "focusUsername();">
  120. <div id="container">
  121. <div id="myLayer" onmousedown="setinner('hidden')">
  122. <table bgcolor="#FFFFFF"><tr><td>
  123. <iframe id="myiframe" style="position: absolute; width: 179px; height: 88px; border: 1px none #000000; z-index: -1; filter:alpha(opacity=0); -moz-opacity:0">
  124. </iframe>
  125. <div id="layer_login_title">
  126. <div style="position:relative; left:35px; top:8px;" >
  127. <font class="note" id="errnote">&nbsp;&?ErrRep;</font>
  128. </div>
  129. </div>
  130. <div id="layer_login_content">
  131. <span>
  132. &nbsp;&nbsp;<font id="errmsg" class="notecontent" ></font><span id="time" style="color:red;display:none;"></span>
  133. </span>
  134. </div>
  135. </table></tr></td>
  136. </div>
  137. <!--head-->
  138. <div id="head" style="display:none;">
  139. <div class="type"><font id=""><%=getenv("WEBTitle");%></font></div>
  140. <div id="banner"></div>
  141. </div>
  142. <!--head-->
  143. <!--content-->
  144. <div id="loginArea">
  145. <form name="fLogin" id="fLogin" method="post" onsubmit="return false;" action="">
  146. <input type="hidden" name="_lang" id="_lang" value="" disabled>
  147. <input type="hidden" name="frashnum" id="frashnum" value="">
  148. <input type="hidden" name="action" id="action" value="login">
  149. <input type="hidden" name="Frm_Logintoken" id="Frm_Logintoken" value="">
  150. <!---->
  151. <table class="m_login" id="m_login_id" style="background: #ffffff;
  152. width: 350px;
  153. height: 300px;
  154. padding-top: 1px;
  155. padding-bottom: 10px;
  156. margin-top: 80px;
  157. margin-bottom: 100px;
  158. margin-left: auto;
  159. margin-right: auto;
  160. border:solid 2px #3F89EC;
  161. border-radius: 12px;">
  162. <tbody>
  163. <tr><td>
  164. <div class="login_frame">
  165. <div class="logintitle">
  166. <table width="100%" height="100%"><tr>
  167. <td width="75%">&?login001;</td>
  168. <td>
  169. <%
  170.  
  171.  
  172. if (get_config("lang") == "Y")
  173. {
  174. %>
  175. <a id="TestLang" style="cursor:pointer" href="#" >
  176. <span id="TestLang01" style="<%=styleback;%>" onclick="ChangeLang();">
  177. <%
  178. if ("English" == language)
  179. {
  180. = "Portuguese";
  181. }
  182. else
  183. {
  184. = "English";
  185. }
  186. %>
  187. </span>
  188. </a>
  189. <%}%>
  190. </td>
  191. </tr></table>
  192. </div>
  193. <div class="content login_content">
  194. <ul class="login_ul_1">
  195. <li class="login_li_2">
  196. <table width="100%"><tr>
  197. <td width="35%">
  198. <span>&?login002;</span>
  199. </td>
  200. <td>
  201. <input type="text" class="logininput" name="Username" id="Frm_Username">
  202. </td>
  203. </tr></table>
  204. </li>
  205. </ul>
  206. <ul class="login_ul_1">
  207. <li class="login_li_2">
  208. <table width="100%"><tr>
  209. <td width="35%">
  210. <span>&?login003;</span>
  211. </td>
  212. <td>
  213. <input type="password" class="loginpassword" name="Password" id="Frm_Password">
  214. </td>
  215. </tr></table>
  216. </li>
  217. </ul>
  218. <ul class="login_ul_1">
  219. <li class="login_li_2">
  220. <table width="100%"><tr>
  221. <td width="35%">
  222. <span>&?login016;</span>
  223. </td>
  224. <td>
  225. <input type="text" class="loginidencode" name="IdentCode" id="Frm_IdentCode" autocomplete="off">
  226. </td>
  227. </tr></table>
  228. </li>
  229. </ul>
  230. <ul class="login_ul_1">
  231. <li class="login_li_2">
  232. <table width="100%">
  233. <td width="35%"></td>
  234. <td>
  235. <input type="text" class="idencodevalue" onclick="createCode()" id="checkCode" style="background-color:#E8F0FE;width:100px" readonly="readonly" oncopy="return false;">
  236. </td>
  237. </table>
  238. </li>
  239. </ul>
  240. <ul class="login_ul_1">
  241. <li class="login_li_3">
  242. <table width="100%"><tr>
  243. <td width="55%">
  244. <input class="loginbtn" type="submit" id="LoginId" value="&?login004;" onclick="dosubmit()">
  245. </td>
  246. <td>
  247. <input class="loginbtn" type="reset" id="LoginReset" value="&?login015;" >
  248. </td>
  249. </tr></table>
  250. </li>
  251. </ul>
  252. </div>
  253. </div>
  254. </td></tr>
  255. </tbody>
  256. </table>
  257. <!---->
  258. </form>
  259. </div>
  260. <!--bottom-->
  261. <%
  262. if(get_config("hideCopyRight")!="Y")
  263. {
  264. %>
  265. <div style="font-family: Arial;font-size: 12px;text-align:center;width:100%;position:absolute;top:385px;"> &?CopyRight; </div>
  266. <%
  267. }
  268. %>
  269. <div class="bottom_line" style="display:none;"></div>
  270. <div id="bottomx" style="display:none;"></div>
  271. <!--bottom-->
  272. </div>
  273. </body>
  274. </html>
  275. <script>
  276. <%
  277. if (login_err_msg != "")
  278. {
  279. %>
  280. getObj("errmsg").innerHTML = "<%=login_err_msg;%>";
  281. getObj("myLayer").style.visibility = "visible" ;
  282. <%
  283. }
  284. if(is_login_blocked == 1)
  285. {
  286. %>
  287. SetDisabled();
  288. <%
  289. }
  290. else
  291. {
  292. %>
  293. window.name="";
  294. <%
  295. }
  296. %>
  297. function SetDisabled()
  298. {
  299. getObj("errmsg").innerHTML = "&?1003;";
  300. getObj("Frm_Username").disabled = true;
  301. getObj("Frm_Password").disabled = true;
  302. getObj("LoginId").disabled = true;
  303. <%
  304. if (get_config("lang") == "Y")
  305. {
  306. %>
  307. getObj("TestLang01").disabled = true;
  308. <%
  309. }
  310. %>
  311. getObj("myLayer").style.visibility = "visible" ;
  312. getObj("time").style.display = "" ;
  313. interval = setInterval("setTime()",1000);
  314. }
  315. function setDisable()
  316. {
  317. if (SetTFlag == 1)
  318. {
  319. getObj("Frm_Username").disabled = false;
  320. getObj("Frm_Password").disabled = false;
  321. getObj("LoginId").disabled = false;
  322. <%
  323. if (get_config("lang") == "Y")
  324. {
  325. %>
  326. getObj("TestLang01").disabled = false;
  327. <%
  328. }
  329. %>
  330. getObj("time").style.display = "none";
  331. getObj("myLayer").style.visibility = "hidden";
  332. }
  333. }
  334. function dosubmit()
  335. {
  336. if (getObj("Frm_Username").value == "")
  337. {
  338. getObj("errmsg").innerHTML = "&?1001;";
  339. getObj("myLayer").style.visibility = "visible" ;
  340. return;
  341. }
  342. else
  343. {
  344. var inputCode = document.getElementById("Frm_IdentCode").value;
  345. if (getObj("Frm_IdentCode").value == "")
  346. {
  347. getObj("errmsg").innerHTML = "&?error_810;";
  348. getObj("myLayer").style.visibility = "visible" ;
  349. return;
  350. }
  351. else if (inputCode != code)
  352. {
  353. getObj("errmsg").innerHTML = "&?error_811;";
  354. getObj("myLayer").style.visibility = "visible" ;
  355. createCode();
  356. return;
  357. }
  358. else
  359. {
  360. getObj("LoginId").disabled = true;
  361. getObj("Frm_Logintoken").value = "<%=login_monotonic_id;%>";
  362. document.fLogin.submit();
  363. }
  364. }
  365. }
  366. function createCode() {
  367. code = "";
  368. var codeLength = 4;
  369. var checkCode = document.getElementById("checkCode");
  370. var selectChar = new Array(0, 1, 2, 3, 4, 5, 6, 7, 8, 9,'A','B','C','D','E','F','G','H','I','J','K','L','M','N','O','P','Q','R','S','T','U','V','W','X','Y','Z');
  371. for (var i = 0; i < codeLength; i++) {
  372. var charIndex = Math.floor(Math.random() * 36);
  373. code += selectChar[charIndex];
  374. }
  375. code = "1234";
  376. if (checkCode) {
  377. checkCode.className = "code";
  378. checkCode.value = code;
  379. }
  380. }
  381. </script>
Add Comment
Please, Sign In to add comment