this html code runs  like this                                              Login                                                                                     Home                                         abcda books                                               {{!-- {{{body}}} --}}                                                      Login                                                 Login                                         wdltyarwgb               --------------   how could i hide the password .like i enter 1234 ,it shows 1234 ,how could i hide it ,make lt shows like ****** or sth else like black dot like this .

Database System Concepts
7th Edition
ISBN:9780078022159
Author:Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Publisher:Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Chapter1: Introduction
Section: Chapter Questions
Problem 1PE
icon
Related questions
Question

this html code runs  like this 

<!DOCTYPE html>
<html lang="en">
    <head>
        <meta charset="UTF-8">
        <meta name="viewport" content="width=device-width, initial-scale=1.0">
        <meta http-equiv="X-UA-Compatible" content="ie=edge">
        <link rel="stylesheet" href="/css/style.css">

        <title>Login</title>

        <script type="application/javascript">
            function validate() {
                const data = new URLSearchParams();
                data.append('name', document.getElementById("name").value);
                data.append("password", document.getElementById("password").value);
                var params = { name: document.getElementById("name").value, password: document.getElementById("password").value };
                var request = new XMLHttpRequest();
                request.open("POST", "/api/login");
                request.setRequestHeader("Content-type", "application/x-www-form-urlencoded");
                request.onload = function () {
                    var result = JSON.parse(request.response);
                    if (result.status === "y") {
                        window.location.href = "/index";
                    } else {
                        alert(result.meg);
                    }
                };
                request.send(data.toString());
            }
        </script>
    </head>
    <body>
        <header>
            <a href="/"><img src="/images/logo.jpg"></a>
            <nav>
                <ul>
                    <li><a href="/">Home</a></li>
                </ul>
            </nav>
            <h4>abcda books </h4>
         </header>
        <main>
            <section>
                {{!-- {{{body}}} --}}
            </section>
            
            <form action="index.hbs" method="POST" id="loginForm">
                <caption><h2>Login</h2></caption>
                <input class="form-control" type="text" name="name" id="name" placeholder="enter account" />
                <input class="form-control" type="text" name="password" id="password" placeholder="enter password" />
                <button type="button" class="btn btn-block btn-danger" onclick="validate()" id="btnLogin">Login</button>
            </form>
        </main>
        <footer>
            <a>wdltyarwgb </a></p>
        </footer> 
    </body>
</html>

--------------

 

how could i hide the password .like i enter 1234 ,it shows 1234 ,how could i hide it ,make lt shows like ****** or sth else like black dot like this .

• Home
abcda books
{{!-- {{{body}}} --}
Login
enter account
1234
Login
wdltyarwgb
Transcribed Image Text:• Home abcda books {{!-- {{{body}}} --} Login enter account 1234 Login wdltyarwgb
Expert Solution
steps

Step by step

Solved in 3 steps with 1 images

Blurred answer
Knowledge Booster
Image Element
Learn more about
Need a deep-dive on the concept behind this application? Look no further. Learn more about this topic, computer-science and related others by exploring similar questions and additional content below.
Similar questions
  • SEE MORE QUESTIONS
Recommended textbooks for you
Database System Concepts
Database System Concepts
Computer Science
ISBN:
9780078022159
Author:
Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Publisher:
McGraw-Hill Education
Starting Out with Python (4th Edition)
Starting Out with Python (4th Edition)
Computer Science
ISBN:
9780134444321
Author:
Tony Gaddis
Publisher:
PEARSON
Digital Fundamentals (11th Edition)
Digital Fundamentals (11th Edition)
Computer Science
ISBN:
9780132737968
Author:
Thomas L. Floyd
Publisher:
PEARSON
C How to Program (8th Edition)
C How to Program (8th Edition)
Computer Science
ISBN:
9780133976892
Author:
Paul J. Deitel, Harvey Deitel
Publisher:
PEARSON
Database Systems: Design, Implementation, & Manag…
Database Systems: Design, Implementation, & Manag…
Computer Science
ISBN:
9781337627900
Author:
Carlos Coronel, Steven Morris
Publisher:
Cengage Learning
Programmable Logic Controllers
Programmable Logic Controllers
Computer Science
ISBN:
9780073373843
Author:
Frank D. Petruzella
Publisher:
McGraw-Hill Education