Hi, i have this code.
$editFormAction = htmlspecialchars($_SERVER['PHP_SELF']);
if (isset($_SERVER['QUERY_STRING'])) {
$editFormAction .= "?" . htmlentities($_SERVER['QUERY_STRING']);
}
with a form with a post method that executes this: in the form "action": echo $editFormAction
and add these inputs:
<input type="hidden" name="<?= $TokenNameKey ?>" value="<?= $TokenName ?>"><!-- CSRF token name -->
<input type="hidden" name="<?= $TokenValueKey ?>" value="<?= $TokenValue ?>"><!-- CSRF token value -->
which appear null to me, but it does not make it clear to me that I have to follow another path.
if ((isset($_POST["MM_insert"])) && ($_POST["MM_insert"] == "proveedor")) {
// y etc.. validations.
I get a 404 error when I send it to the route that ends up being in index.php. it is a custom file