header routing
This commit is contained in:
parent
005ec377d8
commit
ef47d7082c
3 changed files with 41 additions and 19 deletions
|
|
@ -1 +1,13 @@
|
|||
hello from nginx!
|
||||
|
||||
<button onclick="goToApp('java')">Go to Java</button>
|
||||
<button onclick="goToApp('dotnet')">Go to .NET</button>
|
||||
<script>
|
||||
function goToApp(appName) {
|
||||
fetch("/", {
|
||||
headers: { "X-App-Type": appName },
|
||||
})
|
||||
.then((r) => r.text())
|
||||
.then((t) => (document.body.innerHTML = t));
|
||||
}
|
||||
</script>
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue