<?php include_once 'entity_email.php'; ?> <?php if ($_SESSION['role'] != 'associate') { ?> <tr> <td align="center" colspan="2"> <input type="submit" id="submit_user" value="update" /> </td> </tr> <?php } ?> </table> </form> </div> <?php if ($_POST) { $id = $_POST['id']; $name = addslashes($_POST['name']); $name_code = $_POST['name_code']; $address = $_POST['address']; session_start(); $obj->update_user($id, $name, $name_code, $address); } ?> </body> </html>
if ($_GET['action'] == 'edit') { $id = $_GET['id']; $obj->edit_user($id); } if (isset($_REQUEST['action']) && $_REQUEST['action'] == 'delete') { $id = $_REQUEST['id']; $obj->delete_user($id); } if ($_POST) { $id = $_POST['id']; $name = addslashes($_POST['name']); $name_code = $_POST['name_code']; $address = addslashes($_POST['address']); $entity_type = addcslashes($_POST['entity_type']); session_start(); $obj->update_user($id, $name, $name_code, $address, $entity_type); } ?> <html> <head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> <title>Update Entity</title> <link rel="stylesheet" href="css/custom.css" /> <link rel="stylesheet" href="css/menu.css" /> <script src="js/jquery-1.8.3.min.js"></script> <script src="js/custom.js"></script> <style> #addEmail {background: none repeat scroll 0 0 #000000;color: #FFFFFF;padding: 3px;cursor: pointer;} .removeEmail {background: none repeat scroll 0 0 #8d8d8d;color: #FFFFFF;padding: 3px;cursor: pointer;} </style> </head>