atikons Posted February 21, 2006 Report Share Posted February 21, 2006 Ir interneta lapa ar formu. Encoding lapai utf-8. Dati tiek saglabāti mysql datu bāzē, taču līdz DB (insert.php) burts "ā", rādās normāli kā burts "ā", taču kad tas tiek ievietots DB, tas tiek pārveidots vai nu uz Ä? vai citi latviešu simboli uz kaut ko tādu &123; Hostings - serveris.lv. Datu bāzē viss ko vien varēja, nomainīts uz utf-8_unicode_ci. Ja vada pa taisno no phpmyadmin, tad viss OK. MySQL pārvērš "ā" uz "Ä?" ievietošanas brīdī. wtf, kas par vainu? Link to comment Share on other sites More sharing options...
GedroX Posted February 21, 2006 Report Share Posted February 21, 2006 Pamēģini pirms laist savu db ierakstīšanas skriptu, palaist vēl mysql_query('SET CHARSET UTF8'); Link to comment Share on other sites More sharing options...
atikons Posted February 21, 2006 Author Report Share Posted February 21, 2006 Nekas nemainās Link to comment Share on other sites More sharing options...
Roze Posted February 21, 2006 Report Share Posted February 21, 2006 Pareizi būtu pirms kverijiem (pēc conecta): mysql_query("SET NAMES 'utf8'"); mysql_query("SET CHARACTER SET 'utf8'"); Link to comment Share on other sites More sharing options...
atikons Posted February 22, 2006 Author Report Share Posted February 22, 2006 (edited) danke, viss kārtībā Edited February 22, 2006 by atikons Link to comment Share on other sites More sharing options...
Recommended Posts