GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

No menu could be recovered. Follow the blue links in the page.

This view

  • Original page
  • New address

GeezerVison is showing javascript.info — A simple page

  • Tutorial
  • The JavaScript language
  • JavaScript Fundamentals
  • Interaction: alert, prompt, confirm
back to the lesson

A simple page

importance: 4

Create a web-page that asks for a name and outputs it.

Run the demo

JavaScript-code:

let name = prompt("What is your name?", "");
alert(name);

The full page:

<!DOCTYPE html>
<html>
<body>

  <script>
    'use strict';

    let name = prompt("What is your name?", "");
    alert(name);
  </script>

</body>
</html>
You are visitor 01402503 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.