|
@@ -1,49 +0,0 @@
|
|
|
-<!DOCTYPE html>
|
|
|
-<html lang="en">
|
|
|
-
|
|
|
-<head>
|
|
|
- <meta charset="UTF-8">
|
|
|
- <meta http-equiv="X-UA-Compatible" content="IE=edge">
|
|
|
- <meta name="viewport" content="width=device-width, initial-scale=1.0">
|
|
|
- <title>Js1</title>
|
|
|
-</head>
|
|
|
-
|
|
|
-<body>
|
|
|
- <style>
|
|
|
- .div-two {
|
|
|
- background: green;
|
|
|
- }
|
|
|
- .div {
|
|
|
- background: red;
|
|
|
- }
|
|
|
- </style>
|
|
|
- <form id="myForm">
|
|
|
- <input type="login" placeholder="Login"> <br>
|
|
|
- <input type="password" placeholder="Password"> <br>
|
|
|
- <input type="submit" value="Login">
|
|
|
- </form>
|
|
|
- <script>
|
|
|
- let credentials = {
|
|
|
- login: 'admin',
|
|
|
- password: 'qwerty',
|
|
|
- };
|
|
|
- const form = document.querySelector( "myForm" );
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
- // if (login && password) {
|
|
|
- // let div = document.createElement('div');
|
|
|
- // div.className = "div_two";
|
|
|
- // div.innerHTML = "<strong>Всё фигня, давай по новой! Попробуй ввести: admin и qwerty!</strong>"
|
|
|
- // document.body.append(div);
|
|
|
- // }
|
|
|
- // else {
|
|
|
- // let div = document.createElement('div');
|
|
|
- // div.className = "div";
|
|
|
- // div.innerHTML = "<strong>Всё фигня, давай по новой! Попробуй ввести: admin и qwerty!</strong>"
|
|
|
- // document.body.append(div);
|
|
|
- // }
|
|
|
- </script>
|
|
|
-</body>
|
|
|
-
|
|
|
-</html>
|