diff --git a/SignUp/signup.html b/SignUp/signup.html
index d4a3506..21ed35b 100644
--- a/SignUp/signup.html
+++ b/SignUp/signup.html
@@ -88,7 +88,12 @@
Create Your Account
-
+
+
+
+
diff --git a/SignUp/signup.js b/SignUp/signup.js
index cb655e7..9bc5b4b 100644
--- a/SignUp/signup.js
+++ b/SignUp/signup.js
@@ -22,6 +22,45 @@ document.addEventListener("DOMContentLoaded", () => {
registerUser(userdata);
});
+ document.addEventListener("DOMContentLoaded", function () {
+ const rememberMeCheckbox = document.getElementById("remember-me");
+
+ // Load the Remember Me state from local storage
+ rememberMeCheckbox.checked = localStorage.getItem("rememberMe") === "true";
+
+ // Handle form submission
+ document.querySelector("form").addEventListener("submit", function (event) {
+ event.preventDefault();
+
+ // Save Remember Me state in local storage
+ localStorage.setItem("rememberMe", rememberMeCheckbox.checked);
+
+ // Retrieve form data
+ const formData = {
+ username: document.getElementById("username").value,
+ email: document.getElementById("email").value,
+ password: document.getElementById("password").value,
+ rememberMe: rememberMeCheckbox.checked
+ };
+
+ // Send form data to the server (example AJAX call, replace URL with your endpoint)
+ fetch('/signup', {
+ method: 'POST',
+ headers: {
+ 'Content-Type': 'application/json',
+ },
+ body: JSON.stringify(formData),
+ })
+ .then(response => response.json())
+ .then(data => {
+ console.log('Success:', data);
+ })
+ .catch((error) => {
+ console.error('Error:', error);
+ });
+ });
+ });
+
const registerUser = async (user) => {
try {
const res = await fetch("http://localhost:5000/auth/signup", {
diff --git a/login/login.html b/login/login.html
index 3980ba9..fca003b 100644
--- a/login/login.html
+++ b/login/login.html
@@ -29,7 +29,11 @@
Welcome to Gaming Tools Store!
-
+
+
+