UTF-8 does not work in HTML formats
I have this form:
<form method="post" enctype="multipart/form-data" accept-charset="UTF-8"> But when I pass the symbol Γ©, it turns it into Γ Β©.
Why is this not working? Yes, the MySQL database contains all character sets correctly configured. (Database, tables.) If I manually placed it in the database using Navicat, it displays well on the web page.
In addition, I tried the metatag, setting the title of the content type to no success.
In your HTML, add this meta tag:
<meta http-equiv="Content-Type" content="text/html;charset=UTF-8"> Also add this PHP header at the top of the script:
header("Content-Type: text/html;charset=UTF-8"); [EDIT]:
Another tip is to save the file as UTF-8 without BOM . You can use Notepad ++ or any suitable editor for this.
Make sure you set the connection setting to utf8 :
SET NAMES utf8 There are several reasons for incorrect encoding, there is some help: http://www.sebastianviereck.de/en/php-mysql-special-characters-umlauts-utf8-iso/
Add only accept-charset = "character_set" to the form