<form name="nameFORM" action="/heheh.php" method="post">
<input type="hidden" name="BeforeBase" value="data">
<input type="hidden" name="base" value="valuedata">
</form>
<a href="#" onclick="submitBTN()" class="shadow-lg w-50 btn fw-bold border ">
<script>
function submitBTN() {
document.nameFORM.submit();
}
</script>
//you have to have the form tag in this format
<form id="myFunction" onClick= { myFunction } >
<input type="file" name="fileToUpload" id="myFunction" />
</form>
//from there you would have to create a function
function myFunction() {
document.getElementById("myFunction").submit();
}
//if this does not work, start to pray lol and do a lot of digging in
//the browser, good luck !