Ok, so I have been coding a marketplace script for my website in I been trying to get theses links to work, For some reason when a user clicks on the links the page name doesn't update to the new page that they're viewing the rest of the page update but not the page name. So my links show like this dashboard.php?account=withdraws. on the website the dashboard pagename still shows in never updates. So I have included my PHP code of the dashboard I hope somebody can help me resolve this.
Here's the top of the dashboard
<?php
// Seddeo Page System - Customer Dashboard
DEFINE("IN_SEDDEO", 1);
$pageName = "Dashboard";
$body = "customer-dashboard";
require_once('inc/config.php');
require_once('inc/header.php');
$account = $_GET['account'];
$action = isset($_GET['action']) ? $_GET['action'] : '';
// If no login go to login page
if(!$user->is_logged_in()){
header('Location: signin.php?action=nologin');
}
if(isset($account)) {
require_once("{$account}.php");
} else {
?>
And here's the bottom of the dashboard
<?php require_once('inc/footer.php'); ?>
<?php } ?>
I have also included my PHP code of the withdraw page.
Here's the top of the withdraw page
<?php
// Seddeo Page System - Customer Dashboard
DEFINE("IN_SEDDEO", 1);
$pageName = "Account Settings";
$body = "dashboard-settings";
require_once('inc/config.php');
require_once('inc/header.php');
$account = $_GET['account'];
$action = isset($_GET['action']) ? $_GET['action'] : '';
// If no login go to login page
if(!$user->is_logged_in()){
header('Location: signin.php?action=nologin');
}
?>
Very bottom of the page
<?php require_once('inc/footer.php'); ?>
So I hope somebody can help me resolve this issue, thank you.
Ok so here's my header file
<?php
// Create a session only if we don't have one
if (session_status() !== PHP_SESSION_ACTIVE)
{ session_start();
}
// User data
$myID = ($_SESSION["userID"]) ?: null;
$ownerIP = ($_SERVER["REMOTE_ADDR"]) ?: null;
$myUser = ($_SESSION["username"]) ?: null;
if(!empty($myUser)) {
$db->update('UPDATE members SET lastActive = NOW() WHERE username = ?', array($myUser));
$info = $db->fetch("SELECT * FROM members WHERE username = ?", array($myUser));
$rank = $info['rank'];
$regIP = $info['ownerIP'];
$lastLoginIP = $info['lastLoginIP'];
$id = $info['memberID'];
$my_Avatar = $info['my_Avatar'];
$myMembership = $info['myMembership'];
$account_type = $info['account_type'];
}
// Verified Page
if(!DEFINED("IN_SEDDEO"))
{
die("You cannot access this file directly.");
}
if($account_type == 1) {
$isAccount = true;
} else {
$isAccount = false;
}
?>
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<!-- viewport meta -->
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1">
<meta name="description" content="MartPlace - Complete Online Multipurpose Marketplace HTML Template">
<meta name="keywords" content="app, app landing, product landing, digital, material, html5">
<title>Seddeo - <?php echo $pageName; ?></title>
<!-- inject:css -->
<link rel="stylesheet" href="css/animate.css">
<link rel="stylesheet" href="css/font-awesome.min.css">
<link rel="stylesheet" href="css/fontello.css">
<link rel="stylesheet" href="css/jquery-ui.css">
<link rel="stylesheet" href="css/lnr-icon.css">
<link rel="stylesheet" href="css/owl.carousel.css">
<link rel="stylesheet" href="css/slick.css">
<link rel="stylesheet" href="css/trumbowyg.min.css">
<link rel="stylesheet" href="css/bootstrap/bootstrap.min.css">
<link rel="stylesheet" href="style.css">
<!-- endinject -->
<!-- Favicon -->
<link rel="icon" type="image/png" sizes="16x16" href="images/favicon.png">
</head>