teddy / README.md
teddygee's picture
<!DOCTYPE html> <html lang="en"> <head> <meta charset="UTF-8"> <title>School Library Borrowing System</title> <style> body { font-family: Arial, sans-serif; background: #f2f2f2; padding: 20px; } h1 { text-align: center; color: #333; } .form-container { max-width: 600px; margin: auto; background: white; padding: 20px; box-shadow: 0 0 10px rgba(0,0,0,0.1); border-radius: 10px; } input, select, button { width: 100%; padding: 10px; margin: 8px 0; border: 1px solid #ccc; border-radius: 5px; } table { width: 90%; margin: 30px auto; border-collapse: collapse; background: white; } th, td { padding: 12px; border: 1px solid #ccc; text-align: center; } th { background-color: #4CAF50; color: white; } </style> </head> <body> <h1>School Library Borrowing System</h1> <div class="form-container"> <form id="borrowForm"> <label>Admission Number:</label> <input type="text" id="admission" required> <label>Book Number:</label> <input type="text" id="bookNumber" required> <label>Book Name:</label> <input type="text" id="bookName" required> <label>Class:</label> <select id="class" required> <option value="">Select Class</option> <option value="Form 1">Form 1</option> <option value="Form 2">Form 2</option> <option value="Form 3">Form 3</option> <option value="Form 4">Form 4</option> </select> <label>Stream:</label> <select id="stream" required> <option value="">Select Stream</option> <option value="North">North</option> <option value="South">South</option> <option value="East">East</option> <option value="West">West</option> </select> <button type="submit">Borrow Book</button> </form> </div> <table id="borrowLog"> <thead> <tr> <th>Admission #</th> <th>Book #</th> <th>Book Name</th> <th>Class</th> <th>Stream</th> </tr> </thead> <tbody> <!-- Borrowed entries will appear here --> </tbody> </table> <script> document.getElementById('borrowForm').addEventListener('submit', function(e) { e.preventDefault(); const admission = document.getElementById('admission').value; const bookNumber = document.getElementById('bookNumber').value; const bookName = document.getElementById('bookName').value; const className = document.getElementById('class').value; const stream = document.getElementById('stream').value; const table = document.getElementById('borrowLog').getElementsByTagName('tbody')[0]; const newRow = table.insertRow(); newRow.innerHTML = ` <td>${admission}</td> <td>${bookNumber}</td> <td>${bookName}</td> <td>${className}</td> <td>${stream}</td> `; // Clear form this.reset(); }); </script> </body> </html> - Initial Deployment
d2e0abb verified
|
Raw History Blame Contribute Delete
207 Bytes
metadata
title: teddy
emoji: 🐳
colorFrom: yellow
colorTo: gray
sdk: static
pinned: false
tags:
  - deepsite

Check out the configuration reference at https://huggingface.co/docs/hub/spaces-config-reference