mirror of
https://github.com/neosubhamoy/neosubhamoy-portfolio.git
synced 2025-12-20 02:19:34 +05:30
(feature): implemented dynamic socials section for mobile navbar
This commit is contained in:
@@ -34,13 +34,13 @@
|
||||
<h6 class="font-bold mb-8">Follow Me On</h6>
|
||||
<?php
|
||||
|
||||
$socials = fetch_all_records($conn, "socials");
|
||||
|
||||
if($socials -> num_rows > 0) {
|
||||
$footer_socials = fetch_all_records($conn, "socials");
|
||||
|
||||
if($footer_socials -> num_rows > 0) {
|
||||
//show all social links
|
||||
while($social = $socials -> fetch_assoc()) {
|
||||
while($footer_social = $footer_socials -> fetch_assoc()) {
|
||||
echo "
|
||||
<a class='text-sm text-accent_three my-1 hover:text-accent_secondary transition transform duration-100' href='".$social['link']."' target='_blank'>".$social['platform']."</a>
|
||||
<a class='text-sm text-accent_three my-1 hover:text-accent_secondary transition transform duration-100' href='".$footer_social['link']."' target='_blank'>".$footer_social['platform']."</a>
|
||||
";
|
||||
}
|
||||
}
|
||||
|
||||
@@ -58,12 +58,20 @@ function isPageActive($pageName) {
|
||||
<div class="mobilemenufooter w-full flex flex-col mb-20">
|
||||
<button class="mx-6 px-7 py-2 border-[2px] border-accent_primary rounded-lg hover:rounded-lg hover:shadow-lg hover:shadow-accent_primary_transparent transition transform duration-500" onclick="location.href='contact.php'">Let's Talk</button>
|
||||
<div class="flex justify-center items-center mt-7 text-xl">
|
||||
<i class="fa-brands fa-facebook text-accent_primary mx-2" onclick="window.open('https://www.facebook.com/profile.php?id=100076097318726')"></i>
|
||||
<i class="fa-brands fa-instagram text-accent_primary mx-2" onclick="window.open('https://instagram.com/neo_subhamoy')"></i>
|
||||
<i class="fa-brands fa-twitter text-accent_primary mx-2" onclick="window.open('https://twitter.com/neo_subhamoy')"></i>
|
||||
<i class="fa-brands fa-linkedin text-accent_primary mx-2" onclick="window.open('https://www.linkedin.com/in/neo-subhamoy')"></i>
|
||||
<i class="fa-brands fa-github text-accent_primary mx-2" onclick="window.open('https://github.com/neosubhamoy')"></i>
|
||||
<i class="fa-brands fa-mastodon text-accent_primary mx-2" onclick="window.open('https://mastodon.social/@neo_subhamoy')"></i>
|
||||
<?php
|
||||
|
||||
$header_socials = fetch_all_records($conn, "socials");
|
||||
|
||||
if($header_socials -> num_rows > 0) {
|
||||
//show all social links
|
||||
while($header_social = $header_socials -> fetch_assoc()) {
|
||||
echo "
|
||||
<i class='text-accent_primary mx-2 ".$header_social['icon']."' onclick=\"window.open('".$header_social['link']."')\"></i>
|
||||
";
|
||||
}
|
||||
}
|
||||
|
||||
?>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -3,5 +3,5 @@
|
||||
<link href="https://fonts.googleapis.com/css2?family=Cormorant+Upright&family=Lexend+Deca:wght@100;300;400&family=Poppins&display=swap" rel="stylesheet">
|
||||
<link rel="stylesheet" href="assets/style.css">
|
||||
<link rel="stylesheet" href="assets/extra-style.css">
|
||||
<script src="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.4.0/js/all.min.js" integrity="sha512-fD9DI5bZwQxOi7MhYWnnNPlvXdp/2Pj3XSTRrFs5FQa4mizyGLnJcN6tuvUS6LbmgN1ut+XGSABKvjN0H6Aoow==" crossorigin="anonymous" referrerpolicy="no-referrer"></script>
|
||||
<script src="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.4.2/js/all.min.js" integrity="sha512-uKQ39gEGiyUJl4AI6L+ekBdGKpGw4xJ55+xyJG7YFlJokPNYegn9KwQ3P8A7aFQAUtUsAQHep+d/lrGqrbPIDQ==" crossorigin="anonymous" referrerpolicy="no-referrer"></script>
|
||||
<script src="https://code.jquery.com/jquery-3.7.0.js" integrity="sha256-JlqSTELeR4TLqP0OG9dxM7yDPqX1ox/HfgiSLBj8+kM=" crossorigin="anonymous"></script>
|
||||
Reference in New Issue
Block a user