<form>
<label for="mail">I would like you to provide me an e-mail</label>
<input type="email" id="mail" name="mail">
<button>Submit</button>
</form>
var email = document.getElementById("mail");
email.addEventListener("keyup", function (event) {
if (email.validity.typeMismatch) {
email.setCustomValidity("I expect an e-mail, darling!");
} else {
email.setCustomValidity("");
}
});
.block>img {
transition: all 1s;
max-width: 200px;
max-height: 200px
}
.block>img:hover {
transform: rotate(360deg);
border-radius: 50%
}
<input type="text" oninput="this.value = this.value.replace(/[^0-9]/g, '')">
<table>
<tr>
<td>1</td>
</tr>
</table>
<table>
<tr>
<td>2</td>
</tr>
</table>
<table>
<tr>
<td>3</td>
</tr>
</table>
table {
width: 33.3%;
border: 1px solid black;
float: left;
}
<!DOCTYPE html>
<html>
<head>
<title>Main page</title>
</head>
<body></body>
</html>
<!DOCTYPE html>
<html>
<head>
<title>About us</title>
</head>
<body></body>
</html>
<!DOCTYPE html>
<html>
<head>
<title>Contacts</title>
</head>
<body></body>
</html>
each TITLE in["Main page", "About us", "Contacts"]
html
head
title= TITLE
body
<nav>
<ul>
<li><a href="" class="chbg" data-bg="1-bg.jpg">Ссылка 1</a></li>
<li><a href="" class="chbg" data-bg="2-bg.jpg">Ссылка 2</a></li>
<li><a href="" class="chbg" data-bg="3-bg.jpg">Ссылка 3</a></li>
</ul>
</nav>
<div class="index-bg"></div>
$(document).on('ready', function(){
$('.chbg').on('mouseover', function(){
var url = $(this).data('bg');
$('.index-bg').css({"background-image": "url("+url+")"});
});
});