0

hello
i have problem with my code
i try to delete user but i have some problem with that
i cant to delete it...

if((mysql_num_rows($resultAdmin)))
		{
			if(mysql_num_rows($result) > 0)
			{					
			?>

			<table align="left" border="2" cellspacing="0" cellpadding="3">
			<tr><td>Name</td><td>Email</td><td>Phone</td></tr>
			<?php
			$str = "";
			while ($row = mysql_fetch_array($result, MYSQL_ASSOC)) {
			$name = $row["name"];
			$email = $row["email"];
			$phone = $row["phone"];
			
				echo "<tr><td>$name</td><td>$email</td><td>$phone</td></tr>\n";
			}
			?>
				</table>
				<br />
				<table align="left" border="0" cellspacing="0" cellpadding="3">
				<tr><td>Enter the email of the user that you want to delete:</td><td><input type="text" name="EmailDel" maxlength="30"></td><td><input type="submit" name="btnDel" value="Delete"></td></tr>
				</table>
				
				
			<?php 
			if(isset($_POST['btnDel'])){ // the program not run it when i click on submit! why???
					echo "asdasd";
					DeleteUser($_POST['EmailDel']);
					}
			}
			else
			{
				die("no details");
			}
		}
		else
		{
		  die("wrong password");
		}
5
Contributors
4
Replies
5
Views
5 Years
Discussion Span
Last Post by vimalnath53
0

Your input should be between the <form></form> tags and the form should have an action attribute set to the same page.

Edited by broj1: n/a

This topic has been dead for over six months. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.