Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <label class="col-sm-3 control-label">Picture</label>
- <div class="col-sm-9">
- <div class="fileinput fileinput-new" data-provides="fileinput">
- <div class="fileinput-preview thumbnail" data-trigger="fileinput" style="width: 200px; height: 150px;"><img style="height:200px;width:200px" src="http://192.000.00.00/~website/images/employee/<?php echo $row["emp_pic"] ?>"></div>
- <div>
- <span class="btn btn-default btn-file"><span class="fileinput-new">Select image</span><span class="fileinput-exists">Change</span><input type="file" name="k" value="http://192.000.00.00/~website/images/employee/<?php echo $row["emp_pic"] ?>"></span>
- <a href="#" class="btn btn-default fileinput-exists" data-dismiss="fileinput">Remove</a>
- </div>
- </div>
- </div>
- </div>
- <form method="post" action="actions/add.php" class="form-horizontal row-border" enctype="multipart/form-data">
- <?php
- session_start();
- include('../../includes/db_connection.php');
- ob_start();
- $k = $_POST['k'];
- $target = "../../images/employee/";
- $target = $target .$_FILES['k']['name'];
- $picc=$_FILES['k']['name'];
- $pic=($_FILES['k']['tmp_name']);
- move_uploaded_file($pic, $target);
- $ins = mysql_query("UPDATE ehr_employee SET emp_specialization='$sp', emp_fname ='$b', emp_mname='$c', emp_lname='$d', emp_contact='$e', `emp_address`='$f', `emp_bday`='$g', `emp_doc_reg`='$h', `emp_pic`='$picc' where emp_id= $a ");
- $inss = mysql_query("UPDATE ehr_user SET user_username ='$x', user_password='$y' where emp_id= $a ");
- $inserted_record = mysql_affected_rows();
- $_SESSION["A"] = "EE" ;
- header('Location: ' . $_SERVER['HTTP_REFERER']);
- ?>
- <div class="form-group">
- <label class="col-sm-3 control-label">First Name</label>
- <div class="col-sm-6">
- <input type="text" class="form-control" name="b" id="b" readonly="readonly" value="<?php echo $row['emp_fname'] ?>">
- </div>
- </div>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement