Pergunta

When I receive the POST header from this form in my server it has some weird padding added to it. Does anyone have an idea why it looks like this? I don't have problems receiving other headers in my java server.

Server receive this:

POST /%C3%A2%E2%82%AC%C2%9Dindex.html%C3%A2%E2%82%AC%C2%9D HTTP/1.1

HTML:

<!DOCTYPE html>
   <html>
      <body>

       <form method="post" action=”index.html”>
         Login name: <input type="text" name="name"><br>
         Password: <input type=”password” name=”pass”><br>
            <input type="submit" value="Submit">
        </form>

     <p>Register here.</p>

       </body>
     </html>

Thank you.

Foi útil?

Solução

<form method="post" action=”index.html”>
...
Password: <input type=”password” name=”pass”>

Note the different quotation marks. You should be using ASCII character 34, ". Your action attribute is using , which is Unicode code point 8221. That is the strange stuff being embedded in your post; you can see the E2 and 9D in there.

Outras dicas

just look at the the input quote in action not the right one should be action="index.html" also input password got the same problem

Licenciado em: CC-BY-SA com atribuição
Não afiliado a StackOverflow
scroll top