1

I have an HTML form as follows <form action="upload.php" method="post" enctype="multipart/form-data" accept-charset="UTF-8">

One of my inputs is a text input, which is supposed to handle characters such as . I want to handle this by translating it to some sort of html entity, but php's htmlentities always returns an empty string. I can't just remove characters like this because I need to translate them back from a remote application in the future.

Does anyone have any suggestions? I've tried similar questions such as Handling UTF characters in html form submission with no luck

Community
  • 1
  • 1
Daiwik Daarun
  • 3,804
  • 7
  • 33
  • 60
  • Try using your browser's debugger (Firefox and Chrome have good ones). Take a look at the network tab and see what's actually being sent to and from the browser. Try to pinpoint the root cause of the problem, then ask how to fix it. – James Watkins Apr 22 '15 at 03:10

1 Answers1

2

Most browsers don't handle 'accept-charset' in forms anymore. Have you tried the html meta tag utf-8?

<meta charset="utf-8"> 
Aiken
  • 272
  • 1
  • 8