Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Implement responsive navbar and include on all pages #27

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
4 changes: 2 additions & 2 deletions aboutus.php
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,8 @@
</head>

<body>
<!-- Navbar (if applicable) -->
<!-- Include Navbar from another file or code it here -->
<!-- Include the navbar -->
<?php include 'includes/navbar.inc.php'; ?>

<!-- Main Content -->
<div class="container mt-5">
Expand Down
3 changes: 3 additions & 0 deletions game_list.php
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,9 @@
</head>

<body>
<!-- Include the navbar -->
<?php include 'includes/navbar.inc.php'; ?>

<div class="container mt-5">
<!-- Page Heading -->
<h1>Welcome to GamePulse!</h1>
Expand Down
25 changes: 25 additions & 0 deletions includes/navbar.inc.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
<nav class="navbar navbar-expand-md bg-dark text-light py-3">
<div class="container">
<a class="navbar-brand text-light" href="#">GamePulse</a>

<button class="navbar-toggler bg-light" type="button" data-bs-toggle="collapse" data-bs-target="#navbarSupportedContent" aria-controls="navbarSupportedContent" aria-expanded="false" aria-label="Toggle navigation">
<span class="navbar-toggler-icon"></span>
</button>

<div class="collapse navbar-collapse justify-content-end" id="navbarSupportedContent">
<ul class="navbar-nav">
<li class="nav-item">
<a class="nav-link text-white" href="index.php">Home</a>
</li>

<li class="nav-item">
<a class="nav-link text-white" href="game_list.php">Games List</a>
</li>

<li class="nav-item">
<a class="nav-link text-white" href="aboutus.php">About Us</a>
</li>
</ul>
</div>
</div>
</nav>
3 changes: 3 additions & 0 deletions index.php
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,9 @@
</head>

<body>
<!-- Include the navbar -->
<?php include 'includes/navbar.inc.php'; ?>

<!-- Hero Banner -->
<section class="hero-banner text-center py-5">
<div class="container">
Expand Down