Ćwiczenie 10.1:
Rozbuduj poniższy formularz do wprowadzenia danych osobowych.
<!DOCTYPE html>
<html>
<head>
<title>Dane osobowe</title>
<meta charset="utf-8"/>
<script>
'use strict';
function show(form){
alert('Imię: '+form.firstName.value);
}
</script>
</head>
<body>
<form onsubmit='show(this); return false;'>
<p><label for='firstNameField'>Imię:</label>
<input type="text" name='firstName'
id='firstNameField'
required='required'
placeholder='Wpisz swoje imię'
autofocus='autofocus' />
</p>
</form>
</body>
</html>
show, żeby wyświetlał (w jednym alercie) wszystkie zebrane dane