Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <!DOCTYPE html>
- <?php
- $servername = "localhost";
- $username = "root";
- $password = "";
- $dbname = "student_course_management";
- // Create connection
- $conn = new mysqli($servername, $username, $password, $dbname);
- // Check connection
- if ($conn->connect_error) {
- die("Connection failed: " . $conn->connect_error);
- } else {
- $sql = "INSERT INTO student (name, email, password) VALUES ('John', 'john@example.com', 123456)";
- if ($conn->query($sql) === TRUE) {
- echo "New record created successfully";
- } else {
- echo "Error: " . $sql . "<br>" . $conn->error;
- }
- $conn->close();;
- }
- ?>
- <html lang="en">
- <head>
- <meta charset="utf-8">
- <title>scms</title>
- <link href="css/main.css" rel="stylesheet">
- </head><!--/head-->
- <body style = "background-color:#C8C0BE;">
- <header id="header"><!--header-->
- <div class="header-middle"><!--header-middle-->
- <div class="container">
- <div class="row">
- <div class="name">
- <h1 style="color:#2C3539"><center>Student_course_management_system</center></h1>
- </div>
- </div>
- </div>
- </div><!--/header-middle-->
- </header><!--/header-->
- <section id="form"><!--form-->
- <div class="container">
- <div class="row">
- <div class="login-form"><!--login form-->
- <h2 style = "color:#2C3539;">Login to your account</h2>
- <form action ="login.php" method = "post">
- <input type="text" name="na" placeholder="Email" />
- <input type="password" name="pa" placeholder="Password" />
- <span>
- <input type="checkbox" class="checkbox" style="color:#2C3539">Keep me signed in</span>
- <button type="submit" name="submit" class="btn btn-default">Login</button>
- </form>
- </div><!--/login form-->
- </div>
- </div>
- </section><!--/form-->
- <footer id="footer"><!--Footer-->
- <div class="footer-top">
- <div class="container">
- <div class="row">
- </div>
- </div>
- </div>
- <div class="footer-bottom">
- <div class="container">
- <div class="row">
- <p class="pull-left">Copyright © 2016 scms All rights reserved.</p>
- </div>
- </div>
- </div>
- </footer><!--/Footer-->
- </body>
- </html>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement