polycule-connect/polyculeconnect/static/scripts/index.js

12 lines
345 B
JavaScript
Raw Permalink Normal View History

2023-10-15 18:11:50 +00:00
let connectorForm = document.getElementById("connectorform");
connectorForm.addEventListener("submit", (e) => {
e.preventDefault();
let nextURL = new URL(window.location.href);
let connectorName = document.getElementById("cname").value;
nextURL.searchParams.append("connector_id", connectorName)
window.location.href = nextURL;
});