use System\Helper; /** * @var $model System\Models\User */ ?> <div id="registration"> <a href="?page=singin<?php echo \System\Helper::getLang(); ?> " class="btn"><?php echo \System\Helper::lang('sing_in'); ?> </a> <form action="/?page=registration<?php echo \System\Helper::getLang(); ?> " method="post" enctype="multipart/form-data" > <span class="form-label"><?php echo Helper::lang('registration'); ?> </span> <fieldset> <legend><?php echo Helper::lang('access_data'); ?> </legend> <p> <label for="login"><?php echo Helper::lang('login'); ?>
header('Location: /' . \System\Helper::getLang()); } break; case 'profile': if (\System\Models\Auth::isLogin()) { $profile = \System\Models\User::get(); if ($profile) { View::render('profile', ['profile' => $profile]); } else { \System\Models\Auth::logOut(); header('Location: /' . \System\Helper::getLang()); } } else { header('Location: /' . \System\Helper::getLang()); } break; case 'logout': \System\Models\Auth::logOut(); header('Location: /' . \System\Helper::getLang()); break; default: View::render('404' . \System\Helper::getLang()); } ?> <?php } ?> </div> <footer></footer> </body> </html>