<?php
session_start();
?>

<!doctype html>
<html>

<head>
	<meta charset="utf-8">
	<title>Untitled Document</title>

	<style type="text/css">
		bode {
			text-align: center
		}

		;

		header {
			width: 900px;
			margin: 0px auto;
			text-align: left;
		}

		h1,
		h3 {
			text-align: center;
			font-family: "B titr";

		}

		header ul {
			width: 900px;
			padding: 2px;
			border-top: 2px solid #000;
			border-bottom: 2px solid #000;
			text-align: center;
			margin-left: auto;
			margin-right: auto;
			font-family: "Lucida Grande", "Lucida Sans Unicode", "Lucida Sans", "DejaVu Sans", Verdana, sans-serif;
		}

		li {
			display: inline;
			margin: 0px 30px;
			font-size: 16;

		}

		a {
			text-decoration: none;
			color: darkmagenta;


		}

		img {
			width: 300;
			height: 250px;
			border: 1px solid #d6d6d6;

			margin-bottom: 20px;

		}

		tabel {
			text-align: right;
		}
	</style>
</head>

<body>
	<header style="background-color: aquamarine;">
		<h1> فروشگاه انلاین مبل هفشجان</h1>
		<nav>

			<ul>
				<li><a href="index.php"><strong><em>صفحه اصلی</em></strong></a></li>


				<li><strong><em><a href="register.php">عضویت در سایت</a></em></strong></li>

				<span style="font-size: 18px"><strong><em>
							<?php
							if (isset($_SESSION["state_login"]) && $_SESSION["state_login"] === true) {
							?>
						</em>
					</strong>
				</span>
				<li><strong><em><a href="logout.php">خروج از سایت آقا/خانم <?php echo ("{$_SESSION['name']}"); ?></a></em></strong></li>
				<span style="font-size: 18px"><strong><em>
						<?php
							} else {
						?>
						</em>
					</strong>
				</span>


				<li><strong><em><a href="login.php">ورود به سایت</a></em></strong></li>

				<span style="font-size: 18px"><strong><em>
						<?php
							}
						?>
						<?php

						if (
							isset($_SESSION["state_login"]) && $_SESSION["state_login"] === true && $_SESSION['user_type'] === "admin"
							&& $_SESSION['type'] === 1
						) {
						?>
						</em>
					</strong>
				</span>
				<li><strong><em><a href="perodact.php">مدیریت سایت</a></em></strong></li>
				<span style="font-size: 18px"><strong><em>
						<?php
						}
						?>

						</em>
					</strong>
				</span>
				<li><strong><em><a href="nazar.php">در باره ما</a></em></strong></li>



			</ul>



		</nav>


	</header>

</body>

</html>