forked from FladeX/homakov.github.com
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathguc2.html
More file actions
21 lines (20 loc) · 742 Bytes
/
guc2.html
File metadata and controls
21 lines (20 loc) · 742 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
<script>
if(location.search.substr(0,2)=='?i'){
document.write('<iframe style="opacity:0" src="http://translate.google.com/translate?hl=en&sl=en&tl=ru&u=http%3A%2F%2Fhomakov.github.io%2Fguc2.html%3F162"></iframe>');
window.onmessage=function(){window.close();}
}else{
// under GUC
wait = setInterval(function(){
try{
// we need to go deeper...
// parent is GT, parent.parent is ?i page
var el = parent.parent.opener.frames[0].document.getElementsByClassName('page')[0];
if(el){
el.innerHTML='<h1>Hey! Russia needed some rebranding. We are Mango Federation now!</h1>';
clearInterval(wait);
parent.parent.postMessage('closeme','*')
}
}catch(e){}
}, 100);
}
</script>