48 lines
1.9 KiB
HTML
48 lines
1.9 KiB
HTML
<html><head><title>Test MultiInstall Debug</title>
|
|
<script src="/plugins/jquery.min.js"></script>
|
|
<script src="/scripts/global/iresponse.min.js"></script>
|
|
</head><body>
|
|
<h2>Debug Page</h2>
|
|
<div id="debug" style="background:#f0f0f0;padding:10px;margin:10px;font-family:monospace;white-space:pre-wrap;"></div>
|
|
<button id="multi-start-installation" style="padding:20px;font-size:18px;background:green;color:white;cursor:pointer;">TEST BULK INSTALL BUTTON</button>
|
|
<script>
|
|
var d = document.getElementById("debug");
|
|
function dbg(msg) { d.textContent += msg + "\n"; console.log(msg); }
|
|
|
|
dbg("1. jQuery: " + (typeof jQuery));
|
|
dbg("2. Wevads: " + (typeof Wevads));
|
|
dbg("3. $: " + (typeof $));
|
|
|
|
var s = document.createElement("script");
|
|
s.src = "/scripts/pages/servers/multiInstall.js?v=" + Date.now();
|
|
s.onload = function() {
|
|
dbg("4. Script loaded OK");
|
|
dbg("5. multiInstall type: " + (typeof multiInstall));
|
|
if (typeof multiInstall !== "undefined") {
|
|
dbg("6. multiInstall.init exists: " + (typeof multiInstall.init));
|
|
try {
|
|
multiInstall.init();
|
|
dbg("7. init() called successfully");
|
|
} catch(e) {
|
|
dbg("7. init() ERROR: " + e.message);
|
|
dbg(" Stack: " + e.stack.split("\n").slice(0,3).join("\n"));
|
|
}
|
|
try {
|
|
var el = document.getElementById("multi-start-installation");
|
|
var events = $._data(el, "events");
|
|
dbg("8. Events: " + JSON.stringify(events ? Object.keys(events) : "none"));
|
|
if (events && events.click) dbg("9. Click handlers: " + events.click.length);
|
|
} catch(e) {
|
|
dbg("8. Events error: " + e.message);
|
|
}
|
|
} else {
|
|
dbg("5. multiInstall is UNDEFINED - script executed but var not set");
|
|
}
|
|
};
|
|
s.onerror = function(e) {
|
|
dbg("4. Script FAILED TO LOAD");
|
|
};
|
|
document.body.appendChild(s);
|
|
</script>
|
|
</body></html>
|