commit jun 24
This commit is contained in:
84
news.php
84
news.php
@@ -95,20 +95,36 @@
|
||||
</ul>
|
||||
</div>
|
||||
<img src="assets/images/logo.webp" class="logo-img mt-3 mt-lg-0 mt-md-0" alt="">
|
||||
<div class="dropdown" id="dropdownid" style="position: absolute; width:fit-content;">
|
||||
<!-- Login -->
|
||||
<div class="dropdown" id="dropdownid" style="position: absolute; width: fit-content;">
|
||||
<a class="btn btn-secondary dropdown-toggle" href="#" role="button" id="dropdownMenuLink" data-bs-toggle="dropdown" aria-expanded="false">
|
||||
<i class="fa-solid fa-users"></i>
|
||||
|
||||
</a>
|
||||
<ul class="dropdown-menu" aria-labelledby="dropdownMenuLink">
|
||||
<?php if (loggedin()) {
|
||||
<?php
|
||||
if (loggedin()) {
|
||||
echo '<li><a class="dropdown-item" href="php/logout.php">Log out</a></li>';
|
||||
|
||||
if (is_admin()) {
|
||||
echo '<li><a class="dropdown-item" href="admin_panel.php">Admin panel</a></li>';
|
||||
}
|
||||
} else {
|
||||
echo '<li><a class="dropdown-item" href="login.html">Log in</a></li>
|
||||
<li><a class="dropdown-item" href="signup.php">Sign up</a></li>';
|
||||
} ?>
|
||||
<li><a class="dropdown-item" href="signup.php">Sign up</a></li>';
|
||||
}
|
||||
?>
|
||||
|
||||
</ul>
|
||||
</div>
|
||||
<!-- Weather icon -->
|
||||
|
||||
<?php if (loggedin()) {
|
||||
echo '<div class="weather-div" style="position: absolute; color: white; font-size: 25px; left:12%; top:15px;">
|
||||
<a style="color:white" href="weather.php"><i class="fa-solid fa-cloud-sun"></i></a>
|
||||
|
||||
<div>';
|
||||
} ?>
|
||||
|
||||
|
||||
<!-- site navigation-->
|
||||
|
||||
@@ -568,38 +584,40 @@
|
||||
</div>
|
||||
</section>
|
||||
|
||||
<!-- footer -->
|
||||
<footer class="d-flex flex-column justify-content-center align-items-center pb-4 py-lg-5 py-md-5">
|
||||
<div class="scrollToTopBtn">
|
||||
<button onclick="topFunction()" id="scrollToTopBtn"><i class="fa-solid fa-chevron-up"></i></button>
|
||||
</div>
|
||||
<img src="assets/images/footer-logo.webp" class="mt-3 mt-md-0" alt="">
|
||||
<div class="footer-copyright">
|
||||
(c)2024 Globaly. All rights reserved. |
|
||||
<a href="#">Privacy Policy</a>
|
||||
</div>
|
||||
</footer>
|
||||
<!-- footer -->
|
||||
<footer class="d-flex flex-column justify-content-center align-items-center pb-4 py-lg-5 py-md-5">
|
||||
<div class="scrollToTopBtn">
|
||||
<button onclick="topFunction()" id="scrollToTopBtn"><i class="fa-solid fa-chevron-up"></i></button>
|
||||
</div>
|
||||
<img src="assets/images/footer-logo.webp" class="mt-3 mt-md-0" alt="">
|
||||
<div class="footer-copyright">
|
||||
(c)2024 Globaly. All rights reserved. |
|
||||
<a href="#">Privacy Policy</a>
|
||||
</div>
|
||||
</footer>
|
||||
|
||||
<script>
|
||||
// Get the button
|
||||
let mybutton = document.getElementById("scrollToTopBtn");
|
||||
<script>
|
||||
// Get the button
|
||||
let mybutton = document.getElementById("scrollToTopBtn");
|
||||
|
||||
window.onscroll = function() {scrollFunction()};
|
||||
window.onscroll = function() {
|
||||
scrollFunction()
|
||||
};
|
||||
|
||||
function scrollFunction() {
|
||||
if (document.body.scrollTop > 20 || document.documentElement.scrollTop > 20) {
|
||||
mybutton.style.display = "block";
|
||||
} else {
|
||||
mybutton.style.display = "none";
|
||||
}
|
||||
}
|
||||
function scrollFunction() {
|
||||
if (document.body.scrollTop > 20 || document.documentElement.scrollTop > 20) {
|
||||
mybutton.style.display = "block";
|
||||
} else {
|
||||
mybutton.style.display = "none";
|
||||
}
|
||||
}
|
||||
|
||||
// When the user clicks on the button, scroll to the top of the document
|
||||
function topFunction() {
|
||||
document.body.scrollTop = 0;
|
||||
document.documentElement.scrollTop = 0;
|
||||
}
|
||||
</script>
|
||||
// When the user clicks on the button, scroll to the top of the document
|
||||
function topFunction() {
|
||||
document.body.scrollTop = 0;
|
||||
document.documentElement.scrollTop = 0;
|
||||
}
|
||||
</script>
|
||||
<script src="https://code.jquery.com/jquery-3.2.1.slim.min.js" integrity="sha384-KJ3o2DKtIkvYIK3UENzmM7KCkRr/rE9/Qpg6aAZGJwFDMVNA/GpGFF93hXpG5KkN" crossorigin="anonymous"></script>
|
||||
<script src="https://cdn.jsdelivr.net/npm/popper.js@1.12.9/dist/umd/popper.min.js" integrity="sha384-ApNbgh9B+Y1QKtv3Rn7W3mgPxhU9K/ScQsAP7hUibX39j7fakFPskvXusvfa0b4Q" crossorigin="anonymous"></script>
|
||||
<script src="https://cdn.jsdelivr.net/npm/bootstrap@4.0.0/dist/js/bootstrap.min.js" integrity="sha384-JZR6Spejh4U02d8jOt6vLEHfe/JQGiRRSQQxSfFWpi1MquVdAyjUar5+76PVCmYl" crossorigin="anonymous"></script>
|
||||
|
||||
Reference in New Issue
Block a user