File manager - Edit - /home/autoph/public_html/portal/includes/editcompany.php
Back
<html> <head> <title>THE AUTOHUB GROUP</title> <meta charset="utf-8"> <meta name="viewport" content="width=device-width, initial-scale=1"> <link rel="stylesheet" href="css/screen_white.css"> <link rel="stylesheet" href="ajs/vendors/jQueryUI/jquery-ui.css"> <script src="ajs/vendors/jQueryUI/jquery-1.12.4.js"></script> <script src="ajs/vendors/jQueryUI/jquery-ui.js"></script> </head> <?php $id=$_GET['id']; $comName=mysql_result(mysql_query("SELECT `name` FROM `company` WHERE `id`='$id'"),0); $comCode=mysql_result(mysql_query("SELECT `code` FROM `company` WHERE `id`='$id'"),0); $comAddress=mysql_result(mysql_query("SELECT `address` FROM `company` WHERE `id`='$id'"),0); $comTrunk=mysql_result(mysql_query("SELECT `trunk_line` FROM `company` WHERE `id`='$id'"),0); $comFax=mysql_result(mysql_query("SELECT `fax_number` FROM `company` WHERE `id`='$id'"),0); $comEmail=mysql_result(mysql_query("SELECT `email` FROM `company` WHERE `id`='$id'"),0); $accessType = $user_data['account_type']; if($accessType != 'ADMIN' && $accessType!='USER'){ secalert_new(); break; } if(isset($_POST['UpdateRecord'])){ $id=$_GET['id']; $compName =$_POST['compName']; $compCode =$_POST['compCode']; $compAddress =$_POST['compAddress']; $tLine =$_POST['tLine']; $fNumber=$_POST['fNumber']; $cEmail=$_POST['cEmail']; $today = date("m/d/Y"); $diff = date_diff(date_create($dateOfBirth), date_create($today)); $newAge = $diff->format('%y'); mysql_query("UPDATE `company` SET `name`='$compName', `address`='$compAddress',`trunk_line`='$tLine',`fax_number`='$fNumber',`email`='$cEmail' , `date_modified`='$toDate', `modified_by`='$user' WHERE `id`='$id'"); echo "<div class='ContinueMSG'>"; echo " <h3 class='lightGradient' style='width:99%;font-family:Calibri Light;font-size:18px;font-weight:bold;padding-left:5px;padding-top:2px;'>NEW RECORD SAVED...</h3>"; echo "<div style='top:3px;left:95.5%;position:absolute;z-index:3;background:transparent'> <a href='main_new.php?view=100&sid=M1&sview=100&tab=0#id-0' > <center>X</center> </a> </div>"; echo " <h2 style='margin-top:2px;text-align:center;width:100%;font-family:Calibri Light;font-size:16px;font-weight:normal'>RECORD UPDATE COMPLETE...</h2> <center><p style='font-family:Calibri Light;font-size:12px;color:#0B610B;font-weight:normal;padding-top:0px'> Record has been modified...<br><br></a> </p></center>"; echo "</div>"; } ?> <body> <center> <div style='width:98%;border:1px solid white;height:25px;text-align:left;padding-left:10px;padding-top:5px;font-family:Calibri;font-size:14px;color:#000;text-shadow:1px 1px 5px #fff' class='lightGradient'>COMPANY INFORMATION <div style='position:relative;float:right;font-family:Calibri;font-size:12px;margin-right:10px'> </div> </div> <div style='width:98%;border:1px solid #E6E6E6;height:350px;padding:5px'> <form action='' method='POST'> <table style='width:100%;border:1px solid white'> <tr style='background:white;border:1px solid white'> <td valign='top' style='background:white;border:1px solid white;border-right:1px solid white;width:70%'> <div align='left' class="form-group" style='padding:10px'> <p style='text-align:bottom;line-height:80%;font-family:Calibri Light;font-size:12px;padding-left:0px;color:black;font-weight:bold'> <ABBR title='NAME OF COMPANY'> <input REQUIRED class='textbox' type="text" placeholder="COMPANY CODE" name="compCode" value='<?php echo $comCode;?>' style='background:white;width:20%;min-width:220px;margin-top:5px'></ABBR> </p> </div> <div align='left' class="form-group" style='padding:10px'> <p style='text-align:bottom;line-height:80%;font-family:Calibri Light;font-size:12px;padding-left:0px;color:black;font-weight:bold'> <ABBR title='NAME OF COMPANY'> <input REQUIRED class='textbox' type="text" placeholder="COMPANY NAME" name="compName" value='<?php echo $comName;?>' style='background:white;width:90%;min-width:220px;margin-top:5px'></ABBR> </p> </div> <div align='left' class="form-group" style='padding:10px'> <p style='text-align:bottom;line-height:80%;font-family:Calibri Light;font-size:12px;padding-left:0px;color:black;font-weight:bold'> <ABBR title='COMPANY ADDRESS'> <input REQUIRED class='textbox' type="text" placeholder="COMPANY ADDRESS" name="compAddress" value='<?php echo $comAddress;?>' style='background:white;width:90%;min-width:220px;margin-top:5px'></ABBR> </p> </div> <div align='left' class="form-group" style='padding:10px'> <p style='text-align:bottom;line-height:80%;font-family:Calibri Light;font-size:12px;padding-left:0px;color:black;font-weight:bold'> <ABBR title='TRUNKLINE NUMBER'><input REQUIRED class='textbox' type="text" placeholder="TRUNKLINE NUMBER" value='<?php echo $comTrunk;?>' name="tLine" style='background:white;min-width:200px;margin-top:5px'></ABBR> <ABBR title='FAX NUMBER'><input class='textbox' type="text" placeholder="FAX NUMBER" name="fNumber" value='<?php echo $comFax;?>' style='background:white;width:150px;margin-top:5px'></ABBR> <ABBR title='COMPANY E-MAIL'><input REQUIRED class='textbox' type="text" placeholder="COMPANY E-MAIL" name="cEmail" value='<?php echo $comEmail;?>' style='background:white;width:300px;margin-top:5px'></ABBR> <br> <br> </p> </div> </td> </tr> </table> <div align='right' class="form-group" style='padding:10px'> <input type='submit' class='submit' name='UpdateRecord' value='Update Record'> <input type='reset' class='submit' name='Clear' value='Clear'> <a href='main_new.php?view=100&sid=M1&sview=100&tab=0#id-0'><input type='button' class='submit' name='Exit' value='Exit'></a> </div> </form> </div> </center> </body> </html>
| ver. 1.4 |
.
| PHP 7.3.33 | Generation time: 0.01 |
proxy
|
phpinfo
|
Settings