Skip to content

Commit 104194e

Browse files
committed
Update redirect.html
1 parent d5f9289 commit 104194e

File tree

1 file changed

+12
-0
lines changed

1 file changed

+12
-0
lines changed

redirect.html

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -97,6 +97,18 @@
9797
<img class="logo" src="/icons/iphone-app-180.png" width="80" draggable="false" alt="Codeit">
9898
<p class="title">Open mrdoob/threejs with Codeit</p>
9999
<div class="button">Open</div>
100+
101+
<script>
102+
103+
const title = document.querySelector('.title');
104+
const button = document.querySelector('.button');
105+
106+
const url = new URL(window.location.href).searchParams;
107+
108+
title.innerText = url.get('text');
109+
button.onclick = 'window.open('+ url.get('to') +', "_blank")';
110+
111+
</script>
100112
</body>
101113

102114
</html>

0 commit comments

Comments
 (0)