|
@@ -947,7 +947,34 @@ U.MD.D.getNotice = function () {
|
|
|
// video.addEventListener("ended", () => {
|
|
|
// document.body.removeChild(video);
|
|
|
// });
|
|
|
-
|
|
|
+function detectBrowser() {
|
|
|
+ const ua = navigator.userAgent;
|
|
|
+
|
|
|
+ // 按优先级顺序检测
|
|
|
+ if (ua.includes("Edg/") || ua.includes("Edge/")) {
|
|
|
+ return "Microsoft Edge";
|
|
|
+ } else if (ua.includes("Firefox")) {
|
|
|
+ return "Mozilla Firefox";
|
|
|
+ } else if (ua.includes("Trident") || ua.includes("MSIE")) {
|
|
|
+ return "Internet Explorer";
|
|
|
+ } else if (ua.includes("360EE")) {
|
|
|
+ return "360 Browser (极速模式)";
|
|
|
+ } else if (ua.includes("360SE")) {
|
|
|
+ return "360 Browser (安全模式)";
|
|
|
+ } else if (ua.includes("SLBrowser")) {
|
|
|
+ return "QQ Browser";
|
|
|
+ } else if (ua.includes("UCBrowser")) {
|
|
|
+ return "UC Browser";
|
|
|
+ } else if (ua.includes("Opera") || ua.includes("OPR/")) {
|
|
|
+ return "Opera";
|
|
|
+ } else if (ua.includes("Chrome") && !ua.includes("Edg/")) {
|
|
|
+ return "Google Chrome";
|
|
|
+ } else if (ua.includes("Safari/") && !ua.includes("Chrome")) {
|
|
|
+ return "Safari";
|
|
|
+ } else {
|
|
|
+ return "Other Browser";
|
|
|
+ }
|
|
|
+}
|
|
|
U.MD.D.addOp3 = async (userTime, loadTime, object, status) => {
|
|
|
let browser = detectBrowser()
|
|
|
let _time = new Date().toLocaleString('zh-CN', { hour12: false, timeZone: 'Asia/Shanghai' }).replace(/\//g, '-');
|