some subdirectories will display correctly and other wont...
Also these are the folders i have
website
- admin
- add.user.php
- index.php
- login.php
- css
- styles.css
- footer.php
- header.php
- newsletter.php
1. http://localhost/xampp/website/newsletter.php
correct sub...http://localhost/xampp/website/newsletter.php
wrong sub...missing /admin after website http://localhost/xampp/website/add.user.php
wrong sub...missing /admin after website
2. http://localhost/xampp/website/admin/
wrong sub...http://localhost/xampp/website/admin/newsletter.php
correct sub...http://localhost/xampp/website/admin/login.php
3. http://localhost/xampp/website/admin/login.php
wrong sub...http://localhost/xampp/website/admin/newsletter.php
correct sub...http://localhost/xampp/website/admin/login.php
4. http://localhost/xampp/website/admin/login.php
wrong...subhttp://localhost/xampp/website/admin/newsletter.php
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<?php
session_start();
$connect = mysql_connect('localhost', 'root', '') or die(mysql_error());
$db = mysql_select_db('blog', $connect);
$session_name = isset($_SESSION['user_id']) ? $_SESSION['user_id'] : 0;
?>
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>Home - </title>
<link href="css/styles.css" rel="stylesheet" type="text/css" />
<link href="../css/styles.css" rel="stylesheet" type="text/css" />
</head>
<body>
<table border="0" cellspacing="5" cellpadding="3" align="center" width="1024">
<tr>
<td id="header" align="center" valign="top">
<h1>Header here</h1>
</td>
</tr>
<tr>
<td id="navigation" align="center">
<ul>
<li><a href="http://www.#.com/home">Home</a></li> |
<li><a href="http://www.#.com/news">Newsletter</a></li> |
<li><a href="http://www.#.com/deanscolumn">Deans Column</a></li> |
<li><a href="http://www.#.com/photos">Photos</a></li> |
<li><a href="http://www.#.com/jobs">Jobs</a></li> |
<li><a href="http://www.#.com/interships">Interships</a></li> |
<li><a href="http://www.#.com/scholarships">scholarships</a></li> |
<li><a href="http://www.#.com/aboutus">About Us</a></li> |
<li><a href="http://www.#.com/contactus">Contact Us</a></li>
<ul>
</td>
</tr>
<tr>
<td id="admin" align="center">
<?php
if ($session_name) {
echo "<a href=\"./newsletter.php\">Newsletter </a>";
echo "<a href=\"./add.user.php\">Add Admin </a>";
echo "<a href=\"./logout.php\">Logut</a><br>\n";
} else {
echo "<a href=\"./newsletter.php\">Newsletter </a> ";
echo "<a href=\"./login.php\">Login</a>";
}
?>
</td>
</tr>
<tr>
<td id="content">