charsets dosen't properly work after upgrading charsets dosen't properly work after upgrading
 

News:

cpg1.5.48 Security release - upgrade mandatory!
The Coppermine development team is releasing a security update for Coppermine in order to counter a recently discovered vulnerability. It is important that all users who run version cpg1.5.46 or older update to this latest version as soon as possible.
[more]

Main Menu

charsets dosen't properly work after upgrading

Started by okiem, October 19, 2009, 10:17:50 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

okiem

First - I know that is recomended to use utf-8 but ... my gallery is connected with other databses and pages by thousands of links, and after lots of testing I decided to use iso-8859-2

It worked properly on1.4.18 version but after uprgading to 1.4.25 all frazes form language files doesn't display properly special national characters "ąóść..."

User text are OK. Problem is only with language files texts.

I swich in "admin" file language to iso-8859-2, and also gives the same on the begining of language file - NO RESULT
Adter sweching in admin file to utf-8 looks OK (but user text are scrambled)

I thought about change whole gallery to utf-8 but charsetmgr.php doesn't work  - 1.step (checking) gives no result - blank page.

My gallery
version 1.4.25

ps. there is similar topic on support forum, but about older version

Joachim Müller

Quote from: okiem on October 19, 2009, 10:17:50 PMthere is similar topic on support forum, but about older version
All versions of the cpg1.4.x family are the same in this aspect, so if there are other threads that refer to older versions of the cpg1.4.x family than the current cpg1.4.25, they still apply, as there have been no new features since the initial release of the cpg1.4.x series. You should have refered to the threads you already have read.

Quote from: okiem on October 19, 2009, 10:17:50 PMFirst - I know that is recomended to use utf-8 but ... my gallery is connected with other databses and pages by thousands of links, and after lots of testing I decided to use iso-8859-2
I already answered your other thread before seing this one, so this might overlap: yes, it was a bad move to switch from utf-8 to anything else. And basically, you're on your own with this.

Quote from: okiem on October 19, 2009, 10:17:50 PMUser text are OK. Problem is only with language files texts.
You can not just switch encoding around easily once you have textual content in your database. I'm pretty sure that there are other threads that explain how to convert the textual content of the database from a proprietary encoding back to the recommended encoding utf-8. I'm not ready to come up with the instructions again, as they are far from trivial.

Quote from: okiem on October 19, 2009, 10:17:50 PMIt worked properly on1.4.18 version but after uprgading to 1.4.25 all frazes form language files doesn't display properly special national characters "ąóść..."
If the issue happened while upgrading you should have posted that in the proper sub-board, don't you agree? I have moved your thread around accordingly. Can't replicate your issues though.

Quote from: okiem on October 19, 2009, 10:17:50 PMall frazes form language files doesn't display properly special national characters "ąóść..."
Post a deep link or show us a screenshot. As far as I can see your menu entries display as expected in Polish.

okiem

Menu now looked properly but it is just look.
I had to convert whole polish.php file in code. (whole except bbcode help text)

f.e.
a  -   ą
ć - ć
ę - ę

etc.

all numbers are shown on wiki page i line "Unicode

I think, that "$lang_charset" doesn't work properly - because any changing there has no effect.

ps. I wryly tried to search for help in conversion - and I found no treads at all.

Joachim Müller

No, you didn't have to convert that file. That's what I said. You're drawing the wrong conclusions. No need to lecture us about named HTML entities - we're aware of them. If it got necessary for you to convert the encoding of a coppermine core file you must have made a mistake.

okiem

look - I've wryly tried to have wright effect. I used $lang_charset = utf-8 or iso-8859-2 or other, also saving file in different conversion - each of this action gives wrong effect or no effect at all. menu text are always taking by system as unicode, no matter what I wrote on the biggining of poilsh.php (in administrator tools I have iso-8859-2, menu text looked correctly when I use there utf-8 but of course description of file and albums looks bad then)

Therefore only way to have right effect was to CONVERT whole texts in polish.php to HTML entities. I know - that it isn't good solution, but I have no idea haw to do it well. I thought that support forum is for support people who has problem, not to kick them every time when they don't know something.

Joe Carver

Your theme and also your Classic theme returns this before the <head>.

<html dir="ltr">

This does not validate properly. I am not sure if it is the cause of your problem, but the suggestion from here is to return to your template.html(s) the line which is more "standard" to Coppermine version 1.4.25.

<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en" dir="{LANG_DIR}">
(from Sample or Classic themes)

Again, I am not sure if it will fix your problem - but it did not look right.

okiem

Tnak you for help
This become from language (polish.php) file. This is - I believe standard for1.4.25 version and hes explanation
"$lang_text_dir = 'ltr'; // ('ltr' for left to right, 'rtl' for right to left)"
I believe that is option for arabian laganguages

Joachim Müller

This does not come from the polish language file. It comes from your template, exactly as Joe suggested. Edit that file with a plain text editor and replace<html dir="{LANG_DIR}">with<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en" dir="{LANG_DIR}">.
Review your attitude!

okiem

What was wrong with atitude in my last post Joachim?

I did change in my themes file as you suggested. And "<html dir="ltr">" - look still the same
fotogallery, classic, and sample

(but it was not my point - I just did what you suggest)

problem still egsist

okiem

och - I am sorry - i did change in backup dirrectory
ltr-fraze is right

but problem still egsist
for checking I place letter (ą) after note of number of pictures, an pageviews - it should be recognized for you - just above pictures - For not it is seen (Ä�) - and no matter what charset I order in poslih.php

Joachim Müller

Quote from: okiem on October 20, 2009, 08:43:59 PM
What was wrong with atitude in my last post Joachim?
You're lecturing us about how the application we provide is working, e.g. by telling us what the dir attribute of the html tag is used for: we're aware of what that attribute does and why we coded it the way we coded it.

Your site is still using the proprietary encoding that we do not recommend nor support, so every issue you have that is related to using that encoding is entirely your own fault and up to you to fix, as you appear to be immune against advice.

Joachim Müller


phill104

It is a mistake to think you can solve any major problems just with potatoes.

okiem

I agree

But - utf-8 DID NOT give me full possibility what I need (mayby now is better). Espiecially - searching link with polish doesn't work.

I DO believe that utf-8 is the best charset ever made, and I KNOW that i SHOULD use it

Bu - since you give option/possibility to use other charsets - I am asking just about help of it.
I you don't want give me any suppeort why you leave this option for people at all?

I believe that problem is with simple line code which propably don't takes demanding charset form polish.php (I think so - because any change there gives no result)

I believe that is possible to work with other charsets properly. And I am asking of that help - HAW to make the line in polish.php working?!?!?

Joachim Müller

utf-8 is not a charset. Seems like you haven't read the article I have refered to.

okiem

sorry for my english - I just change utf-8 for iso-8859-2 No metter what is the name in english of it)  - in Config file it is "Character encoding"
It should work but doesn't

BTW if it is not charset why in all language file  is "$lang_charset = 'utf-8';" ????

Joe Carver

Quote from: okiem on October 22, 2009, 07:53:29 PM
BTW if it is not charset why in all language file  is "$lang_charset = 'utf-8';" ????

Why keep arguing with the experts? If it read "$lang_encoding would you then understand?

     ########

You seemed to have caused the trouble yourself.

Quote from: okiem on October 19, 2009, 10:17:50 PM
It worked properly on1.4.18 version

Then we see.....

Quote from: okiem on October 20, 2009, 08:53:19 PMi did change in backup dirrectory

From the help menu in Language & Charset settings

QuoteOnce you have added comments or files to your gallery, you should not change the character set of your gallery

Try some of the basic things: review your edits and changes, your backups and also how you make edits to your files (make sure you save all cpg files as UTF-8 without B.O.M.)

okiem

QuoteTry some of the basic things: review your edits and changes, your backups and also how you make edits to your files (make sure you save all cpg files as UTF-8 without B.O.M.)

Yes - I had done this all before I wrote the topic. Few times. I edit files in Notepad++ (UTF-8 without B.O.M. - simple notepad with colored).

I did only few small changes (I marked them all every time)
* in config  for iso-8859-2
* trying new $lang-charset - change for iso... also, and changed back for utf-8.
* extra lines in menu,
* two plugins (user description text displayed, and Captcha plugin).
* change back displaying links [ url ]
* give possibility to display right bb-code help file in html. (by allowed < and >)
* few extra function of private bb-code.
* in search inc.php  ______ $type = $_POST['type'] == 'AND' ? " AND " : " OR ";  ___ for ___ $type = $_REQUEST['type'] == 'AND' ? " AND " : " OR ";

Joachim Müller

Stop the nonsense now, will ya? You seem to be immune against advice, so drop it. If you want our advice, then get a vanilla polish language file (in utf-8) and don't convert nor transmogrify it. After that, convert the textual content of the database tables of your coppermine gallery from iso-whatever to utf-8 (remember to back up evereything before you try) using the corresponding converter.
If you decide not to do exactly I said above, then please stop molesting us with your remarks. You're on your own then.

okiem

as I sad - I also try to do it (translate whole database to utf-8) but charsetmgr.php doesn't work stoping on the 1 step. I tried to look for solution on this forum - but I couldn't find.

please don't be so rude - I always gently asking for help, doing whatever I can, and in each replay recive lashing from you.