Das Resizing script ausgelagert in resize.js

master
Nils Eilinghoff 2023-06-14 12:04:25 +02:00
parent 6334b4ec1f
commit 360d3fdf06
32 changed files with 40 additions and 340 deletions

View File

@ -80,17 +80,7 @@
<!--Link JS file--> <!--Link JS file-->
<script src="burgerIcon.js"></script> <script src="burgerIcon.js"></script>
<script> <script src="resize.js"></script>
var widthissue = false;
window.addEventListener("resize", function(event) {
if(window.innerWidth > 800 && widthissue) {
widthissue = false
unset()
}
else if(window.innerWidth < 800) widthissue = true;
})
</script>
<nav id="activeid" class="active"></nav> <nav id="activeid" class="active"></nav>
@ -133,17 +123,7 @@
<!--Link JS file--> <!--Link JS file-->
<script src="burgerIcon.js"></script> <script src="burgerIcon.js"></script>
<script> <script src="resize.js"></script>
var widthissue = false;
window.addEventListener("resize", function(event) {
if(window.innerWidth > 800 && widthissue) {
widthissue = false
unset()
}
else if(window.innerWidth < 800) widthissue = true;
})
</script>
<nav id="activeid" class="active"></nav> <nav id="activeid" class="active"></nav>

View File

@ -81,17 +81,7 @@ session_destroy();
<!--Link JS file--> <!--Link JS file-->
<script src="burgerIcon.js"></script> <script src="burgerIcon.js"></script>
<script> <script src="resize.js"></script>
var widthissue = false;
window.addEventListener("resize", function(event) {
if(window.innerWidth > 800 && widthissue) {
widthissue = false
unset()
}
else if(window.innerWidth < 800) widthissue = true;
})
</script>
<nav id="activeid" class="active"></nav> <nav id="activeid" class="active"></nav>

View File

@ -105,16 +105,7 @@
</div> </div>
<script> <script src="resize.js"></script>
var widthissue = false;
window.addEventListener("resize", function(event) {
if(window.innerWidth > 800 && widthissue) {
widthissue = false
unset()
}
else if(window.innerWidth < 800) widthissue = true;
})
</script>
<nav id="activeid" class="active"></nav> <nav id="activeid" class="active"></nav>

View File

@ -105,16 +105,7 @@
</div> </div>
<script> <script src="resize.js"></script>
var widthissue = false;
window.addEventListener("resize", function(event) {
if(window.innerWidth > 800 && widthissue) {
widthissue = false
unset()
}
else if(window.innerWidth < 800) widthissue = true;
})
</script>
<nav id="activeid" class="active"></nav> <nav id="activeid" class="active"></nav>

View File

@ -76,17 +76,7 @@
<!--Link JS file--> <!--Link JS file-->
<script src="burgerIcon.js"></script> <script src="burgerIcon.js"></script>
<script> <script src="resize.js"></script>
var widthissue = false;
window.addEventListener("resize", function(event) {
if(window.innerWidth > 800 && widthissue) {
widthissue = false
unset()
}
else if(window.innerWidth < 800) widthissue = true;
})
</script>
<nav id="activeid" class="active"></nav> <nav id="activeid" class="active"></nav>

View File

@ -76,17 +76,7 @@
<!--Link JS file--> <!--Link JS file-->
<script src="burgerIcon.js"></script> <script src="burgerIcon.js"></script>
<script> <script src="resize.js"></script>
var widthissue = false;
window.addEventListener("resize", function(event) {
if(window.innerWidth > 800 && widthissue) {
widthissue = false
unset()
}
else if(window.innerWidth < 800) widthissue = true;
})
</script>
<nav id="activeid" class="active"></nav> <nav id="activeid" class="active"></nav>

View File

@ -233,16 +233,7 @@
<script src="burgerIcon.js"></script> <script src="burgerIcon.js"></script>
<!--If it was small and got big, <!--If it was small and got big,
it calls the function only one time and doesn't do it all the time--> it calls the function only one time and doesn't do it all the time-->
<script> <script src="resize.js"></script>
var widthissue = false;
window.addEventListener("resize", function(event) {
if(window.innerWidth > 800 && widthissue) {
widthissue = false
unset()
}
else if(window.innerWidth < 800) widthissue = true;
})
</script>
<nav id="activeid" class="active"></nav> <nav id="activeid" class="active"></nav>

View File

@ -210,17 +210,7 @@
<!--Link JS file--> <!--Link JS file-->
<script src="burgerIcon.js"></script> <script src="burgerIcon.js"></script>
<script> <script src="resize.js"></script>
var widthissue = false;
window.addEventListener("resize", function(event) {
if(window.innerWidth > 800 && widthissue) {
widthissue = false
unset()
}
else if(window.innerWidth < 800) widthissue = true;
})
</script>
<!--Burger--> <!--Burger-->
<nav id="activeid" class="active"></nav> <nav id="activeid" class="active"></nav>

View File

@ -172,16 +172,7 @@
<script src="burgerIcon.js"></script> <script src="burgerIcon.js"></script>
<!--If it was small and got big, <!--If it was small and got big,
it calls the function only one time and doesn't do it all the time--> it calls the function only one time and doesn't do it all the time-->
<script> <script src="resize.js"></script>
var widthissue = false;
window.addEventListener("resize", function(event) {
if(window.innerWidth > 800 && widthissue) {
widthissue = false
unset()
}
else if(window.innerWidth < 800) widthissue = true;
})
</script>
<nav id="activeid" class="active"></nav> <nav id="activeid" class="active"></nav>

View File

@ -119,16 +119,7 @@
<script src="burgerIcon.js"></script> <script src="burgerIcon.js"></script>
<!--If it was small and got big, <!--If it was small and got big,
it calls the function only one time and doesn't do it all the time--> it calls the function only one time and doesn't do it all the time-->
<script> <script src="resize.js"></script>
var widthissue = false;
window.addEventListener("resize", function(event) {
if(window.innerWidth > 800 && widthissue) {
widthissue = false
unset()
}
else if(window.innerWidth < 800) widthissue = true;
})
</script>
<nav id="activeid" class="active"></nav> <nav id="activeid" class="active"></nav>

View File

@ -76,16 +76,7 @@
<script src="burgerIcon.js"></script> <script src="burgerIcon.js"></script>
<!--If it was small and got big, <!--If it was small and got big,
it calls the function only one time and doesn't do it all the time--> it calls the function only one time and doesn't do it all the time-->
<script> <script src="resize.js"></script>
var widthissue = false;
window.addEventListener("resize", function(event) {
if(window.innerWidth > 800 && widthissue) {
widthissue = false
unset()
}
else if(window.innerWidth < 800) widthissue = true;
})
</script>
<nav id="activeid" class="active"></nav> <nav id="activeid" class="active"></nav>

View File

@ -90,16 +90,7 @@
<script src="burgerIcon.js"></script> <script src="burgerIcon.js"></script>
<!--If it was small and got big, <!--If it was small and got big,
it calls the function only one time and doesn't do it all the time--> it calls the function only one time and doesn't do it all the time-->
<script> <script src="resize.js"></script>
var widthissue = false;
window.addEventListener("resize", function(event) {
if(window.innerWidth > 800 && widthissue) {
widthissue = false
unset()
}
else if(window.innerWidth < 800) widthissue = true;
})
</script>
<nav id="activeid" class="active"></nav> <nav id="activeid" class="active"></nav>

View File

@ -69,16 +69,7 @@
<script src="burgerIcon.js"></script> <script src="burgerIcon.js"></script>
<!--If it was small and got big, <!--If it was small and got big,
it calls the function only one time and doesn't do it all the time--> it calls the function only one time and doesn't do it all the time-->
<script> <script src="resize.js"></script>
var widthissue = false;
window.addEventListener("resize", function(event) {
if(window.innerWidth > 800 && widthissue) {
widthissue = false
unset()
}
else if(window.innerWidth < 800) widthissue = true;
})
</script>
<nav id="activeid" class="active"></nav> <nav id="activeid" class="active"></nav>

View File

@ -68,17 +68,7 @@
<!--Link JS file--> <!--Link JS file-->
<!--If it was small and got big, it calls the function only one time and doesn't do it all the time--> <!--If it was small and got big, it calls the function only one time and doesn't do it all the time-->
<script> <script src="resize.js"></script>
var widthissue = false;
window.addEventListener("resize", function(event) {
if(window.innerWidth > 800 && widthissue) {
widthissue = false
unset()
}
else if(window.innerWidth < 800) widthissue = true;
})
</script>
<nav id="activeid" class="active"></nav> <nav id="activeid" class="active"></nav>

View File

@ -68,17 +68,7 @@
<!--Link JS file--> <!--Link JS file-->
<!--If it was small and got big, it calls the function only one time and doesn't do it all the time--> <!--If it was small and got big, it calls the function only one time and doesn't do it all the time-->
<script> <script src="resize.js"></script>
var widthissue = false;
window.addEventListener("resize", function(event) {
if(window.innerWidth > 800 && widthissue) {
widthissue = false
unset()
}
else if(window.innerWidth < 800) widthissue = true;
})
</script>
<nav id="activeid" class="active"></nav> <nav id="activeid" class="active"></nav>

View File

@ -78,17 +78,7 @@
<!--Link JS file--> <!--Link JS file-->
<!--If it was small and got big, it calls the function only one time and doesn't do it all the time--> <!--If it was small and got big, it calls the function only one time and doesn't do it all the time-->
<script> <script src="resize.js"></script>
var widthissue = false;
window.addEventListener("resize", function(event) {
if(window.innerWidth > 800 && widthissue) {
widthissue = false
unset()
}
else if(window.innerWidth < 800) widthissue = true;
})
</script>
<nav id="activeid" class="active"></nav> <nav id="activeid" class="active"></nav>

View File

@ -78,17 +78,7 @@
<!--Link JS file--> <!--Link JS file-->
<!--If it was small and got big, it calls the function only one time and doesn't do it all the time--> <!--If it was small and got big, it calls the function only one time and doesn't do it all the time-->
<script> <script src="resize.js"></script>
var widthissue = false;
window.addEventListener("resize", function(event) {
if(window.innerWidth > 800 && widthissue) {
widthissue = false
unset()
}
else if(window.innerWidth < 800) widthissue = true;
})
</script>
<nav id="activeid" class="active"></nav> <nav id="activeid" class="active"></nav>

View File

@ -215,17 +215,7 @@ if(isset($_POST['submit'])){
<!--Link JS file--> <!--Link JS file-->
<script src="burgerIcon.js"></script> <script src="burgerIcon.js"></script>
<script> <script src="resize.js"></script>
var widthissue = false;
window.addEventListener("resize", function(event) {
if(window.innerWidth > 800 && widthissue) {
widthissue = false
unset()
}
else if(window.innerWidth < 800) widthissue = true;
})
</script>
<!--Burger--> <!--Burger-->
<nav id="activeid" class="active"></nav> <nav id="activeid" class="active"></nav>

View File

@ -76,17 +76,7 @@
<!--Link JS file--> <!--Link JS file-->
<script src="burgerIcon.js"></script> <script src="burgerIcon.js"></script>
<script> <script src="resize.js"></script>
var widthissue = false;
window.addEventListener("resize", function(event) {
if(window.innerWidth > 800 && widthissue) {
widthissue = false
unset()
}
else if(window.innerWidth < 800) widthissue = true;
})
</script>
<nav id="activeid" class="active"></nav> <nav id="activeid" class="active"></nav>

View File

@ -172,17 +172,7 @@ function register($vorname,
<!--Link JS file--> <!--Link JS file-->
<script src="burgerIcon.js"></script> <script src="burgerIcon.js"></script>
<script> <script src="resize.js"></script>
var widthissue = false;
window.addEventListener("resize", function(event) {
if(window.innerWidth > 800 && widthissue) {
widthissue = false
unset()
}
else if(window.innerWidth < 800) widthissue = true;
})
</script>
<nav id="activeid" class="active"></nav> <nav id="activeid" class="active"></nav>

View File

@ -152,17 +152,7 @@ session_start();
<!--Link JS file--> <!--Link JS file-->
<script src="burgerIcon.js"></script> <script src="burgerIcon.js"></script>
<script> <script src="resize.js"></script>
var widthissue = false;
window.addEventListener("resize", function(event) {
if(window.innerWidth > 800 && widthissue) {
widthissue = false
unset()
}
else if(window.innerWidth < 800) widthissue = true;
})
</script>
<nav id="activeid" class="active"></nav> <nav id="activeid" class="active"></nav>

View File

@ -76,17 +76,7 @@
<!--Link JS file--> <!--Link JS file-->
<script src="burgerIcon.js"></script> <script src="burgerIcon.js"></script>
<script> <script src="resize.js"></script>
var widthissue = false;
window.addEventListener("resize", function(event) {
if(window.innerWidth > 800 && widthissue) {
widthissue = false
unset()
}
else if(window.innerWidth < 800) widthissue = true;
})
</script>
<nav id="activeid" class="active"></nav> <nav id="activeid" class="active"></nav>

View File

@ -232,16 +232,7 @@ TODO (optional):
<script src="burgerIcon.js"></script> <script src="burgerIcon.js"></script>
<!--If it was small and got big, <!--If it was small and got big,
it calls the function only one time and doesn't do it all the time--> it calls the function only one time and doesn't do it all the time-->
<script> <script src="resize.js"></script>
var widthissue = false;
window.addEventListener("resize", function(event) {
if(window.innerWidth > 800 && widthissue) {
widthissue = false
unset()
}
else if(window.innerWidth < 800) widthissue = true;
})
</script>
<nav id="activeid" class="active"></nav> <nav id="activeid" class="active"></nav>

View File

@ -74,17 +74,7 @@
<!--Link JS file--> <!--Link JS file-->
<!--If it was small and got big, it calls the function only one time and doesn't do it all the time--> <!--If it was small and got big, it calls the function only one time and doesn't do it all the time-->
<script> <script src="resize.js"></script>
var widthissue = false;
window.addEventListener("resize", function(event) {
if(window.innerWidth > 800 && widthissue) {
widthissue = false
unset()
}
else if(window.innerWidth < 800) widthissue = true;
})
</script>
<nav id="activeid" class="active"></nav> <nav id="activeid" class="active"></nav>

View File

@ -105,17 +105,7 @@
<!--Link JS file--> <!--Link JS file-->
<!--If it was small and got big, it calls the function only one time and doesn't do it all the time--> <!--If it was small and got big, it calls the function only one time and doesn't do it all the time-->
<script> <script src="resize.js"></script>
var widthissue = false;
window.addEventListener("resize", function(event) {
if(window.innerWidth > 800 && widthissue) {
widthissue = false
unset()
}
else if(window.innerWidth < 800) widthissue = true;
})
</script>
<nav id="activeid" class="active"></nav> <nav id="activeid" class="active"></nav>

8
resize.js 100644
View File

@ -0,0 +1,8 @@
var widthissue = false;
window.addEventListener("resize", function(event) {
if(window.innerWidth > 800 && widthissue) {
widthissue = false
unset()
}
else if(window.innerWidth < 800) widthissue = true;
})

View File

@ -329,16 +329,7 @@
<script src="burgerIcon.js"></script> <script src="burgerIcon.js"></script>
<!--If it was small and got big, <!--If it was small and got big,
it calls the function only one time and doesn't do it all the time--> it calls the function only one time and doesn't do it all the time-->
<script> <script src="resize.js"></script>
var widthissue = false;
window.addEventListener("resize", function(event) {
if(window.innerWidth > 800 && widthissue) {
widthissue = false
unset()
}
else if(window.innerWidth < 800) widthissue = true;
})
</script>
<nav id="activeid" class="active"></nav> <nav id="activeid" class="active"></nav>

View File

@ -85,16 +85,7 @@
<script src="burgerIcon.js"></script> <script src="burgerIcon.js"></script>
<!--If it was small and got big, <!--If it was small and got big,
it calls the function only one time and doesn't do it all the time--> it calls the function only one time and doesn't do it all the time-->
<script> <script src="resize.js"></script>
var widthissue = false;
window.addEventListener("resize", function(event) {
if(window.innerWidth > 800 && widthissue) {
widthissue = false
unset()
}
else if(window.innerWidth < 800) widthissue = true;
})
</script>
<nav id="activeid" class="active"></nav> <nav id="activeid" class="active"></nav>

View File

@ -78,17 +78,7 @@
<!--Link JS file--> <!--Link JS file-->
<!--If it was small and got big, it calls the function only one time and doesn't do it all the time--> <!--If it was small and got big, it calls the function only one time and doesn't do it all the time-->
<script> <script src="resize.js"></script>
var widthissue = false;
window.addEventListener("resize", function(event) {
if(window.innerWidth > 800 && widthissue) {
widthissue = false
unset()
}
else if(window.innerWidth < 800) widthissue = true;
})
</script>
<nav id="activeid" class="active"></nav> <nav id="activeid" class="active"></nav>

View File

@ -78,17 +78,7 @@
<!--Link JS file--> <!--Link JS file-->
<!--If it was small and got big, it calls the function only one time and doesn't do it all the time--> <!--If it was small and got big, it calls the function only one time and doesn't do it all the time-->
<script> <script src="resize.js"></script>
var widthissue = false;
window.addEventListener("resize", function(event) {
if(window.innerWidth > 800 && widthissue) {
widthissue = false
unset()
}
else if(window.innerWidth < 800) widthissue = true;
})
</script>
<nav id="activeid" class="active"></nav> <nav id="activeid" class="active"></nav>

View File

@ -333,16 +333,7 @@ TODO (optional, geringe Priorität):
<script src="burgerIcon.js"></script> <script src="burgerIcon.js"></script>
<!--If it was small and got big, <!--If it was small and got big,
it calls the function only one time and doesn't do it all the time--> it calls the function only one time and doesn't do it all the time-->
<script> <script src="resize.js"></script>
var widthissue = false;
window.addEventListener("resize", function(event) {
if(window.innerWidth > 800 && widthissue) {
widthissue = false
unset()
}
else if(window.innerWidth < 800) widthissue = true;
})
</script>
<nav id="activeid" class="active"></nav> <nav id="activeid" class="active"></nav>

View File

@ -100,17 +100,7 @@ $db_link = mysqli_connect('localhost', 'web_b-3', 'een7Ao6s', 'bibliothek_candle
</div> </div>
</div> </div>
<script> <script src="resize.js"></script>
var widthissue = false;
window.addEventListener("resize", function(event) {
if(window.innerWidth > 800 && widthissue) {
widthissue = false
unset()
}
else if(window.innerWidth < 800) widthissue = true;
})
</script>
<nav id="activeid" class="active"></nav> <nav id="activeid" class="active"></nav>