Welcome Guest, Not a member yet? Register   Sign In
Special Character Bugz
#1

[eluser]1mr3yn[/eluser]
I encountering this kind of problem with CI.,
because when Im trying to save the data in the database from the POST input.,
instead of 'ñ' it will stored a '?' character. Im using uses utf8_general_ci as collation in my tables.


And the database.php setting from config folder:

$db['default']['char_set'] = "utf8";
$db['default']['dbcollat'] = "utf8_general_ci";

Thanks!!!♥♪
#2

[eluser]Thorpe Obazee[/eluser]
If you enter the text with phpmyadmin, do the weird characters show?
#3

[eluser]1mr3yn[/eluser]
Nope... It works fine., if I will use the phpmyadmin.
#4

[eluser]1mr3yn[/eluser]
can someone tell me what's the problem with this???
#5

[eluser]Thorpe Obazee[/eluser]
Did you check if your page encoding is set to utf-8?
#6

[eluser]1mr3yn[/eluser]
Yeah,., and its ok,., Ive try a lot of solutions from other author but still not work..
#7

[eluser]Thorpe Obazee[/eluser]
what do you mean by "it's ok"? Did you get it solved? Did you check the encoding?
#8

[eluser]louis w[/eluser]
Try adding this to your <form> tag

Code:
accept-charset="utf-8"

and make sure your html has this in the head

Code:
<meta http-equiv="Content-type" content="text/html; charset=utf-8" />

And if none of that works, you can try this as a last resort:

Code:
$value = mb_convert_encoding($value,'UTF-8','UTF-8');
#9

[eluser]1mr3yn[/eluser]
thanks "louis w", it works now..
just a little changes in my <meta>
#10

[eluser]Thorpe Obazee[/eluser]
[quote author="bargainph" date="1245935949"]Did you check if your page encoding is set to utf-8?[/quote]

[quote author="r3yn" date="1246093216"]thanks "louis w", it works now..
just a little changes in my <meta>[/quote]

:bug:




Theme © iAndrew 2016 - Forum software by © MyBB