Welcome Guest, Not a member yet? Register   Sign In
Charset, CI or MySQL problem ??? ( or dumb coder problem ??? )

[eluser]Randy Casburn[/eluser]
There is partially, and after this I'm going to submit a bug/suggestion.

The first part of the fix is to the Form Help Class. I'll be asking that they require all forms generated with the form helper respect the char_set encoding declaration provided in the database settings. This would have cut down this and many other problems over the weekend. This is done in the form header by including the HTML keyword [accept-charset = "UTF-8"] inside the <form> tag. Of-course, the char_set would be pulled from the DB config char_set configuration item. in the CI registry.

Now the other part. All you have to do is write a simple parser yourself -> jk...

All you have to do is run your $desc1 and $desc2 through the "String Helpers" quotes_to_entities(); or strip_quotes(); I recommend quotes_to_entities(); like this...

function update_boot_text($bootID, $number, $name, $type, $desc1, $desc2)
    $data = array('catID' => $type, 'Nmbr' => $number, 'Name' => $name, 'desc1' => quotes_to_entities($desc1), 'desc2' => quotes_to_entities($desc2));

Don't forget to load up the String Helper class.


Messages In This Thread
Charset, CI or MySQL problem ??? ( or dumb coder problem ??? ) - by El Forum - 06-30-2008, 05:48 PM

Theme © iAndrew 2016 - Forum software by © MyBB