Skip to content
Snippets Groups Projects
Commit 001a179d authored by Mikhael Artur Darmakesuma's avatar Mikhael Artur Darmakesuma
Browse files

Displayed pref loc in edit pref loc view

parent ba7cabf5
1 merge request!42Projekers - 13515051 - Girvandi Ilyas
File moved
...@@ -107,5 +107,4 @@ class User { ...@@ -107,5 +107,4 @@ class User {
mysqli_close($con); mysqli_close($con);
return $result; return $result;
} }
>>>>>>> c2ae002b0ea1e89875f3cea9e97fbf6eeddd1b39
} }
\ No newline at end of file
...@@ -2,7 +2,7 @@ ...@@ -2,7 +2,7 @@
<head> <head>
<title>Projekers - Login</title> <title>Projekers - Login</title>
<link rel = "stylesheet" href = "../css/primary.css"> <link rel = "stylesheet" href = "../css/primary.css">
<link rel = "stylesheet" href = "../css/login.css"> <link rel = "stylesheet" href = "../css/index.css">
</head> </head>
<body> <body>
<div class = "container"> <div class = "container">
......
...@@ -8,34 +8,53 @@ ...@@ -8,34 +8,53 @@
<body> <body>
<div class = "container"> <div class = "container">
<h1>EDIT PREFERED LOCATION</h1> <h1>EDIT PREFERED LOCATION</h1>
<table class="tab"> <?php
<tr> include "../model/user.php";
<th class="tabno">No</td> $user = new User;
<th class="tabloc">Location</td> $user_id = 1;
<th class="tabact">Actions</td> $result = $user->getPreferredLocation($user_id);
</tr> if ($result->num_rows > 0) {
<tr> echo '
<td class="tabno">1</td> <table class="tab">
<td class="tabloc"> <tr>
<div id="locationtext">Bandung</div> <th class="tabno">No</td>
<input id="locationinput" type="text"> <th class="tabloc">Location</td>
</td> <th class="tabact">Actions</td>
<td class="tabact"> </tr>
<div class="addset" align="center"> ';
<div class="editsavebox"> $i=1;
<button onClick=hideMe() class="editsave"> while($row = $result->fetch_assoc()) {
<img src="../img/pencil.png" class="editsavebutton" id="imageeditsave"> echo '
</button> <tr>
</div> <td class="tabno">'.$i.'</td>
<div> <td class="tabloc">
<button onClick=f() class="delete"> <div id="locationtext">'.$row["location"].'</div>
<img src="../img/delete.png" class="deletebutton"> <input id="locationinput" type="text">
</button> </td>
</div> <td class="tabact">
</div> <div class="addset" align="center">
</td> <div class="editsavebox">
</tr> <button onClick=hideMe() class="editsave">
</table> <img src="../img/pencil.png" class="editsavebutton" id="imageeditsave">
</button>
</div>
<div>
<button onClick=f() class="delete">
<img src="../img/delete.png" class="deletebutton">
</button>
</div>
</div>
</td>
</tr>';
$i++;
}
echo '
</table>
';
} else {
echo "No prefered location, add one using the box below.";
}
?>
<br> <br>
<br> <br>
<h2>ADD NEW LOCATION:</h2> <h2>ADD NEW LOCATION:</h2>
......
<!DOCTYPE html>
<html> <html>
<head> <head>
<title>Login</title> <title>Projekers - Login</title>
</head> <link rel = "stylesheet" href = "../css/primary.css">
<body> <link rel = "stylesheet" href = "../css/index.css">
<h1>Index Page</h1> </head>
</body> <body>
</html> <div class = "container">
\ No newline at end of file <div>
<div class = "horizontal"></div>
<div class = "judul">LOGIN</div>
<div class = "horizontal"></div>
</div>
<div class = "form_input">
<form>
<div class="set">
<div class="label">Username</div>
<div class="field"><input type = "text"></div>
</div>
<div class="set">
<div class="label">Password</div>
<div class="field"><input type = "password"></div>
</div>
<div class="linkset">
<div class="link"><a href="register.php">Don't have an account?</a></div>
<div class="submitbutton">
<input type = "Submit" value = "GO!" class = "submit">
</div>
</div>
</form>
</div>
</div>
</body>
</html>
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment