forked from mirrors/webxoss-core
open window by absolute path
This commit is contained in:
parent
3b85cef504
commit
26b2e19856
1 changed files with 6 additions and 2 deletions
|
@ -43,9 +43,13 @@ function startBattle() {
|
||||||
location.reload();
|
location.reload();
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
var win = window.open('./webxoss-client/?local=true');
|
var relativePath = './webxoss-client/?local=true';
|
||||||
|
var link = document.createElement('a');
|
||||||
|
link.href = relativePath;
|
||||||
|
var absolutePath = link.href;
|
||||||
|
var win = window.open(absolutePath);
|
||||||
win.addEventListener('load', function() {
|
win.addEventListener('load', function() {
|
||||||
var win2 = window.open('./?local=true');
|
var win2 = window.open(absolutePath);
|
||||||
win2.addEventListener('load', function() {
|
win2.addEventListener('load', function() {
|
||||||
initClient(win2);
|
initClient(win2);
|
||||||
skipDiscards();
|
skipDiscards();
|
||||||
|
|
Loading…
Reference in a new issue