www
/
wwwroot
/
magazinmiorita.be
/
admin
➕ New
📤 Upload
✎ Editing:
add_client.php
← Back
<?php include('../includes/inc.config.php'); include('check_session.php'); $regions_results = array(); $regions = $database->execute(" SELECT * FROM `region` "); while($row = $database->fetch($regions)){ $regions_results[] = $row; } if(isset($_POST['add'])){ $email = $_POST['email']; $password = md5($_POST['password']); $fname = $_POST['fname']; $lname = $_POST['lname']; $company = $_POST['company']; $address = $_POST['address']; $zip = $_POST['zip']; $city = $_POST['city']; $region = $_POST['region']; $phone = $_POST['phone']; $ship_address = $_POST['ship_address']; $ship_zip = $_POST['ship_zip']; $ship_city = $_POST['ship_city']; $join = $_POST['join']; $level = $_POST['level']; $status = $_POST['status']; $add_client = $database->execute("INSERT INTO `customers` (`email`, `password`, `fname`, `lname`, `company`, `address`, `zip`, `city`, `region`, `phone`, `ship_address`, `ship_zip`, `ship_city`, `join`, `level`, `status`) VALUES ('$email', '$password', '$fname', '$lname', '$company', '$address', '$zip', '$city', '$region', '$phone', '$ship_address', '$ship_zip', '$ship_city', '".time()."', '$level', '$status')"); if($add_client){ $smarty->assign("type", 'succ'); $smarty->assign("message", 'Client profile added successfully!'); }else{ $smarty->assign("type", 'err'); $smarty->assign("message", 'Client profile can not be created! Please check and try again.'); } } $smarty->assign("regions", $regions_results); $smarty->display(END_PATH.'add_client.tpl'); ?>
💾 Save Changes
Cancel
📤 Upload File
×
Select File
Upload
Cancel
➕ Create New
×
Type
📄 File
📁 Folder
Name
Create
Cancel
✎ Rename Item
×
Current Name
New Name
Rename
Cancel
🔐 Change Permissions
×
Target File
Permission (e.g., 0755, 0644)
0755
0644
0777
Apply
Cancel