Why can not I send the "+" character via post in a simple HTML form?

0

I made a simple page in html that when I received the login and a password it sends to another page where the data is verified, the problem is that when I put the "+" character in the password it simply does not arrive in the post, what arrives is an empty ".

The form header looks like this:

<form action="VerificaLogin.php"method="POST" enctype="multipart/form-data" accept-charset="iso-8859-1">

I have already changed the charset to UTF-8 and it did not work, I already changed the enctype to application / x-www-form-urlencoded / p>

How can I resolve this problem?

    
asked by anonymous 06.06.2018 / 16:24

2 answers

1

I made a treatment with JavaScript, before sending the request I use the encodeURIComponent () function to encode the password string before validating the login on the server, so I was able to use any kind of special character no problem.

    
19.06.2018 / 14:18
1

You're probably using a couple of quotes in the wrong place, your php should be understanding + as an addition and not as a character.

    
06.06.2018 / 19:44