mirror of
https://github.com/gabrielkheisa/meme-generator-nodejs
synced 2025-08-21 11:31:15 +00:00
first
This commit is contained in:
13
public/error.html
Normal file
13
public/error.html
Normal file
@@ -0,0 +1,13 @@
|
||||
<!DOCTYPE html>
|
||||
<html lang="en">
|
||||
<head>
|
||||
<meta charset="UTF-8">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||
<title>Error</title>
|
||||
</head>
|
||||
<body>
|
||||
<h1>Cookie is not set, please return to index</h1>
|
||||
<br>
|
||||
<h2>Please wait... don't refresh</h2>
|
||||
</body>
|
||||
</html>
|
19
public/index.html
Normal file
19
public/index.html
Normal file
@@ -0,0 +1,19 @@
|
||||
<!DOCTYPE html>
|
||||
<html lang="en">
|
||||
<head>
|
||||
<meta charset="UTF-8">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||
<title>Ronaldo</title>
|
||||
</head>
|
||||
<body>
|
||||
<h1>Ronaldo</h1>
|
||||
<form action="/process" method="post">
|
||||
<video src="/video.mp4"></video>
|
||||
<br>
|
||||
<label for="text1">Text: </label>
|
||||
<input type="text" id="text1" name="text1" required>
|
||||
<br>
|
||||
<button type="submit">Submit</button>
|
||||
</form>
|
||||
</body>
|
||||
</html>
|
27
public/process.ejs
Normal file
27
public/process.ejs
Normal file
@@ -0,0 +1,27 @@
|
||||
<!DOCTYPE html>
|
||||
<html lang="en">
|
||||
<head>
|
||||
<meta charset="UTF-8">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||
<title>Processing...</title>
|
||||
</head>
|
||||
<body>
|
||||
<h1>Processing...</h1>
|
||||
<br>
|
||||
<h2 id="check"><%- value %></h2>
|
||||
</body>
|
||||
<script>
|
||||
async function fetchData() {
|
||||
try {
|
||||
const response = await fetch('/check');
|
||||
const data = await response.text();
|
||||
const dataContainer = document.getElementById('check');
|
||||
dataContainer.innerHTML = data;
|
||||
} catch (error) {
|
||||
console.error('Error fetching data:', error);
|
||||
}
|
||||
}
|
||||
|
||||
setInterval(fetchData, 1000);
|
||||
</script>
|
||||
</html>
|
Reference in New Issue
Block a user