Hmm, here is what i did to EditNews_interface.php
Code:
<?php
include('session_vars.php');
// Check to see if they are logged in..
if ($enpw != $pw){
header("Location: ../ad_login.php");}
include('mysql_connect.php');
$id = $_GET['id'] + 0;
if(!is_numeric($id)) die("id is not a number");
$sql = mysql_query("SELECT * FROM news ORDER BY id DESC");
while($row = mysql_fetch_array($sql))
{
?>
<html><head><title></title>
<style>
<!--
a{text-decoration:none}
//-->
</style>
<style>
a:visited{color:blue; text-decoration:none; }
a:active{color:red; text-decoration:none; }
a:link{color:red; text-decoration:none; }
a:hover{color:orange; text-decoration:underline; }
</style>
</head>
<BODY background="../images/image_22.gif">
<div align="left">
<TABLE width="100%" border="0" cellspacing="0" cellpadding="3">
<tr>
<td><b><font face="Verdana, Arial, Helvetica, sans-serif" size="2">
<?php echo $row['title'] . ' | Posted by: ' . $row['name'] . ' on ' . $row['date'] . ' ID# ' . $row['id']; ?></font></b>
</td>
</tr>
<tr>
<td>
[ <a href="EditNews.php?id=<?php echo $id; ?>">Edit Post</a> ] [
<a href="DelNews.php?id=<?php echo $id; ?>">Delete Post</a> ]
</td>
<br>
</tr>
</TABLE>
</div>
</body>
</html>
<?php
}
?>
I changed the links so that the php tags were only around the variable instead of the whole a href tag and now all my link locations say ?id=0 instead of ?id=$id.
I can't seem figure out why it's displaying it as nothing.
{ EDIT | 5 minutes later }
Wooooooooooo !!!!!
I figured $_GET['id'] isnt working properly and I already know that the value of $row['id'] returns the same thing so i switched $id with $row['id'] in my links and now both edit and delete work like a charm
I want to thank all of you who helped me get through this, you have all been very patient and understanding to my skill level. You can bet that I will be chatting on these forums from here on out.
- ViciOuS
aka Ryan