-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathapp.js
30 lines (29 loc) · 1.13 KB
/
app.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
const app = document.querySelector("#appiframe");
var plink = localStorage.getItem("plink")
var sitesrc = 'https://' + plink
if (plink == "r.emulatoros.ga") {
console.log('start ' + sitesrc + ' change');
var site = sitesrc + "/" + app.dataset.applink;
app.setAttribute('id', 'riframe');
app.setAttribute('allowfullscreen', 'true')
app.setAttribute('scrolling', 'yes')
app.src = site;
console.log('finish ' + sitesrc + ' change link');
} else if (plink == "r2.emulatoros.ga") {
console.log('start ' + sitesrc + ' change');
var site = sitesrc + "/" + app.dataset.applink;
app.setAttribute('id', 'r2iframe');
app.setAttribute('allowfullscreen', 'true')
app.setAttribute('scrolling', 'yes')
app.src = site;
console.log('finish ' + sitesrc + ' change link');
} else if (plink == "r3.emulatoros.ga") {
console.log('start ' + sitesrc + ' change');
var site = sitesrc + "/" + app.dataset.applink;
app.setAttribute('id', 'r3iframe');
app.setAttribute('allowfullscreen', 'true')
app.setAttribute('scrolling', 'yes')
app.src = site;
console.log('finish ' + sitesrc + ' change link');
}
console.log(app.dataset.applink);