CodeCharge Studio
search Register Login  

Visual PHP Web Development

Visually Create Internationalized Web Applications, Web Reports, Calendars, and more.
CodeCharge.com

YesSoftware Forums -> CodeCharge Studio -> Tips & Solutions

 UTF-8 without translations

Print topic Send  topic

Author Message
ebweb

Posts: 2
Posted: 11/12/2008, 2:13 AM

I've had a problem with getting everything working in UTF-8. I would set all the encodings and the database to utf-8, but when a utf8 character was pulled from the database (,,) they would be ISO-8859-1 encoded.

The first solution to this was to tick the "Use internationalization features" in Locales and Encodings. Then everything would work, but if I built the project in this mode then every piece of text would require a translation and I'm building a single language solution.

What I found now is that I can get around all of this by leaving the "Use internationalization features" un-ticked and adding

 "Encoding" => array("", "utf8"),

in common.php in the $CCConnectionSettings array.

I can now build a 100% utf8 project without using translations.

(Of course if you regenerate common.php the hack will be removed, but I always generate pages with ctrl+f8 so the common.php remains untouched)
View profile  Send private message
datadoit
Posted: 11/12/2008, 6:25 AM

I would add to this excellent tip by suggesting that ALL new projects
use Internationalization, single language or otherwise. You just never
know when you'll need to add Swahili language support to your app!
SteveG

Posts: 56
Posted: 11/13/2008, 11:06 AM

Worked well for me - thanks!
View profile  Send private message

Add new topic Subscribe to topic   


These are Community Forums for users to exchange information.
If you would like to obtain technical product help please visit http://support.yessoftware.com.

PHP Reports

Visually create Web Reports in PHP, ASP, .NET, Java, Perl and ColdFusion.
CodeCharge.com

Home   |    Search   |    Members   |    Register   |    Login


Powered by UltraApps Forum created with CodeCharge Studio
Copyright 2003-2004 by UltraApps.com  and YesSoftware, Inc.