mod
This commit is contained in:
parent
b6fac28396
commit
f329c944f8
1 changed files with 2 additions and 11 deletions
|
|
@ -11,8 +11,8 @@
|
|||
<p>Enter your Sleeper username to view your fantasy teams</p>
|
||||
|
||||
<!-- Username input form -->
|
||||
<form class="username-form" onsubmit="goToUser(event)">
|
||||
<input type="text" id="username" placeholder="Enter Sleeper username" required>
|
||||
<form class="username-form" method="get" action="/dashboard">
|
||||
<input type="text" name="username" placeholder="Enter Sleeper username" required>
|
||||
<button type="submit">View Dashboard</button>
|
||||
</form>
|
||||
|
||||
|
|
@ -21,13 +21,4 @@
|
|||
</div>
|
||||
</div>
|
||||
|
||||
<script>
|
||||
function goToUser(event) {
|
||||
event.preventDefault(); // Prevent form submission
|
||||
const username = document.getElementById('username').value.trim();
|
||||
if (username) {
|
||||
window.location.href = `/${username}`; // Navigate to user dashboard
|
||||
}
|
||||
}
|
||||
</script>
|
||||
{% endblock %}
|
||||
|
|
|
|||
Loading…
Reference in a new issue