I have a form field on a page called cadastro.php, for example. So I want to create a variable that receives the value that the user types in this field, but I want this variable to be in the same code and not on another page, but I do not know how to get this value, since it is not being passed either via post or via get How?
Type I know it's not like this, but I'll put this example to anyone who wants to respond.
field: <input type="text" name="nome"/>
I want to extract to a variable that will be on the same code page as the value that the user types ...
$nome = $_GET['nome'];
. I know it's not like that, but how do I do it? Or is there no way?