-
-
Save JimStencil/b85d20840179bedbf91a85b369a87fc7 to your computer and use it in GitHub Desktop.
HTML 5 - Validando formato de CPF
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<html> | |
<head> | |
<title>Formato CPF</title> | |
<script src="script.js"></script> | |
</head> | |
<body> | |
<h3>Digite seu CPF:</h3> | |
<form name="cadastro"> | |
<input type="text" name="cpf" \ | |
pattern="\d{3}\.\d{3}\.\d{3}-\d{2}" \ | |
title="Digite um CPF no formato: xxx.xxx.xxx-xx"> | |
<input type="submit" value="Verificar"> | |
</form> | |
</body> | |
</html> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment