Forums / Developer / PHP standard in eZ: using single quotes in strings may cause problem with italian language

PHP standard in eZ: using single quotes in strings may cause problem with italian language

Author Message

Andrea Palladino

Saturday 20 November 2004 9:24:56 am

This sintax may cause problems with some languages (like italian):

$var = 'some text' ;

For example, the package function use a php code (compiled on cache) with:

$var = 'Seleziona un'icona da includere nel pacchetto.<br />
Se non vuoi alcuna icona clicca Successivo.' ;

The string "un'icona" is the correct italian translation for "an icon". Of course the apostrophe is interpreted as a closing quote by php. This will generate a fatal error.

<b>Possible solutions</b>
Change the italian messages with apostrophe (for example: un'icona may be una icona), but this will result on a bad italian...

More solutions?

Marco Zinn

Saturday 20 November 2004 2:51:30 pm

I suggest, that you file a bug report.
The translation system (or the template compiler) should be able to handle "all" characters. This should not be too hard, the apostrophe just needs to be escaped.
But this must be done somewhere in ezpublish's PHP code.

Marco
http://www.hyperroad-design.com

Andrea Palladino

Sunday 21 November 2004 1:41:02 am

I have opened a specifig bug report:

http://www.ez.no/community/bug_reports/php_standard_in_ez_using_single_quotes_in_strings_may_cause_problem_with_italian_language