Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php
- session_start();
- header("Content-Type: text/html; Charset=uft-8");
- $host = 'localhost';
- $user = 'root';
- $password = '';
- $db = 'login';
- $connection = mysqli_connect($host, $user, $password);
- if($connection){
- if(!mysqli_select_db($connection, $db))
- echo "<br>".mysqli_error($connection);
- }else{
- echo "<br>".mysqli_error();
- }
- echo "
- <a href='index2.php?form=register'>Registrieren</a>
- <a href='index2.php?form=login'>Einloggen</a>
- ";
- if(empty($_GET['form']) OR !empty($_GET['form']) AND $_GET['form'] == "register"){
- // Registrierungsformular
- include("register.php");
- }else if(!empty($_GET['form']) AND $_GET['form'] == 'login'){
- // Loginformular
- include("login.php");
- }
- ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement