Day 3 of Login Registration Form Flip using HTML, CSS, and JavaScript for a Website

Posted by

Day 3: Flip Login Registration form

body {
font-family: Arial, sans-serif;
background-color: #f4f4f4;
margin: 0;
padding: 0;
}
.container {
width: 400px;
margin: 100px auto;
background-color: #fff;
padding: 20px;
border-radius: 5px;
box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
}
input[type=”text”],
input[type=”password”],
input[type=”submit”] {
width: 100%;
padding: 10px;
margin: 10px 0;
border: 1px solid #ccc;
border-radius: 3px;
}
input[type=”submit”] {
background-color: #4caf50;
color: #fff;
cursor: pointer;
}

Login

Don’t have an account? Register

Register

Already have an account? Login

document.querySelector(‘a[href=”#registration”]’).addEventListener(‘click’, function() {
document.getElementById(‘registration’).style.display = ‘block’;
document.getElementById(‘login’).style.display = ‘none’;
});
document.querySelector(‘a[href=”#login”]’).addEventListener(‘click’, function() {
document.getElementById(‘login’).style.display = ‘block’;
document.getElementById(‘registration’).style.display = ‘none’;
});

0 0 votes
Article Rating
1 Comment
Oldest
Newest Most Voted
Inline Feedbacks
View all comments
@Gamingzonetest
10 months ago

Nice skills you have on html , css and js