Problem with Polish chars in picture descriptions Problem with Polish chars in picture descriptions
 

News:

CPG Release 1.6.27
change DB IP storage fields to accommodate IPv6 addresses
remove use of E_STRICT (PHP 8.4 deprecated)
update README to reflect new website
align code with new .com CPG website
correct deprecation in captcha

Main Menu

Problem with Polish chars in picture descriptions

Started by pasenger, February 01, 2014, 08:30:30 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

pasenger

After updating the gallery with version 1.5.24 to 1.5.26 swapping files and update the database in the descriptions of pictures appeared in August bushes.

If the file config.inc.php will add $ CONFIG ['dbcharset'] = 'latin2'; descriptions are displayed correctly in the keywords appear in the bushes.

How to solve it?

Αndré

Splitted from http://forum.coppermine-gallery.net/index.php/topic,76135.0.html

Please undo the change in include/config.inc.php and post a link to your gallery, especially some links where we can see the issue.

pasenger

http://www.natorze.com.pl/displayimage.php?pid=809

The problem only for displaying the correct keywords:

instead "Chabówka" displays "Chabówka"

instead "małopolskie displays maÅ�opolskie"

instead "jesień" displays "jesieÅ�"

In the file include / functions.inc.php have modified record descriptions of images to display them properly:

function cpg_db_connect()
{
    global $CONFIG;

    $result = @mysql_connect($CONFIG['dbserver'], $CONFIG['dbuser'], $CONFIG['dbpass']);

    if (!$result) {
        return false;
    }

    if (!mysql_select_db($CONFIG['dbname'])) {
        return false;
    }

    if (empty($CONFIG['dbcharset'])) {
        cpg_db_query("set names latin2", $result);
    }

    return $result;
}


With this modification, include / function.ini.php version 1.5.24 working properly. Version 1.5.26 has a problem with Polish characters in keywords.


Αndré

Please have a look at the (currently) last post of this topic and follow the link to our SVN repository to see how to fix that issue: http://forum.coppermine-gallery.net/index.php/topic,76830.msg372140.html#msg372140


pasenger

Everything works fine after replacing these files. Thank you Andre.