Repository navigation
Expand file tree
/
Copy pathprofile.html
More file actions
executable file
·34 lines (27 loc) · 1.82 KB
/
Copy pathprofile.html
File metadata and controls
executable file
·34 lines (27 loc) · 1.82 KB
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
<?php include "templates/header.html"; ?>
<h1><?= htmlspecialchars($head) ?></h1>
<?php if($error=="emailwrong"):?> <p class="alert-danger" > Неверный формат Email </p><?php endif; ?>
<?php if($error=="emailused"):?> <p class="alert-danger" > Email уже используется </p><?php endif; ?>
<?php if($error=="loginused"):?> <p class="alert-danger" > Login уже используется </p><?php endif; ?>
<form class="form" method="post" action="index.php" class="form-horizontal">
<input type="text" name="login" placeholder="Login" value="<?php if($logined):?><?= htmlspecialchars($user->getLogin())?><?php endif; ?>">
<input type="text" name="email" placeholder="E-mail" value="<?php if($logined):?><?= htmlspecialchars($user->getEmail())?><?php endif; ?>">
<input type="password" name="password" placeholder="Password" >
<input type="submit" name="regsubmit" value="Отправить" class="btn btn-primary">
</form>
<?php if($logined):?>
<form class="form" method="post" action="index.php" class="form-horizontal">
<input type="submit" name="exit" value="Выйти" class="btn btn-primary">
</form>
<?php else:?>
<h1 class="alert-danger" > Войдите </h1>
<?php if($error=="login"):?> <p class="alert-danger" > Неверный формат Login </p><?php endif; ?>
<?php if($error=="passwordwrong"):?> <p class="alert-danger" > Неверный Password </p><?php endif; ?>
<form class="form" method="post" action="index.php" class="form-horizontal">
<input type="text" name="login" placeholder="Login" >
<input type="hidden" name="email" value="login" >
<input type="password" name="password" placeholder="Password" >
<input type="submit" name="logsubmit" value="Войти" class="btn btn-primary">
</form>
<?php endif; ?>
<?php include "templates/footer.html"; ?>