-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathtest
53 lines (46 loc) · 2.23 KB
/
test
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
<?php if (isLoggedIn()) : ?>
<a class="btn green btn-create" href="<?php echo URLROOT ?>/posts/create">
Create
</a>
<?php endif; ?>
<!-- Check if this user is delete own post if not it will not show -->
<?php if ((isset($_SESSION['user_id']) && $_SESSION['user_id'] == $post->user_id) || isAdmin()) : ?>
<div class="wrap">
<?php if (!isAdmin()) : ?>
<a class="btn orange btn-update" href="<?php echo URLROOT . "/posts/update/" . $post->id ?>">
Update
</a>
<?php endif; ?>
<!-- !Check if this user is delete own post if not it will not show -->
<!-- Delete button -->
<form action="<?php echo URLROOT . "/posts/delete/" . $post->id ?>" method="post">
<input type="submit" name="delete" value="delete" class="btn red btn-delete">
</form>
<!-- !Delete button -->
</div>
<?php endif; ?>
register
<!-- <div class="container-login">
<div class="wrapper-login">
<h2>Register </h2>
<form action="<?php echo URLROOT; ?>/users/register" method="POST">
<input type="text" placeholder="UserName *" value="<?php echo $data['username'] ? '' : $data['username'] ?>" name="username" required>
<span class="invalidFeedback">
<?php echo $data['usernameError']; ?>
</span>
<input type="email" placeholder="Email *" value="<?php echo $data['email'] ? '' : $data['email'] ?>" name="email" required>
<span class="invalidFeedback">
<?php echo $data['emailError']; ?>
</span>
<input type="password" placeholder="PassWord *" value="<?php echo $data['password'] ? '' : $data['password'] ?>" name="password" required>
<span class="invalidFeedback">
<?php echo $data['passwordError']; ?>
</span>
<input type="password" placeholder="ConfirmPassword *" value="<?php echo $data['confirmPass'] ? '' : $data['confirmPass'] ?>" name="confirmPass" required>
<span class="invalidFeedback">
<?php echo $data['confirmPassError']; ?>
</span>
<button id="submit" type="submit" value="submit">Submit</button>
</form>
</div>
</div> -->