Advanced search  

News:

CPG Release 1.6.26
Correct PHP8.2 issues with user and language managers.
Additional fixes for PHP 8.2
Correct PHP8 error with SMF 2.0 bridge.
Correct IPTC supplimental category parsing.
Download and info HERE

Pages: [1]   Go Down

Author Topic: Upgrade from CPG 1.3 to CPG 1.4.4 with change of character set  (Read 3817 times)

0 Members and 1 Guest are viewing this topic.

andreseso

  • Coppermine newbie
  • Offline Offline
  • Posts: 1

Hello,

Before I started the upgrade procedure I did a
Code: [Select]
mysqldump with mysqldump -Q --opt -uUser -pPass DBName > cpg.sql
I backed up includes/config.php, my albums directory and the one other file mentioned.  I rsynced my 1.4.4 files over the old installation and I restored the stuff I had backed up. I ran the update.php and switched the language to the original Spanish it was in.  The new Spanish language file was in UTF-8 and my character encodings were latin1 so I had the accents on the CPG options horribly wrong.  I changed the character set in configuration to Utf-8.  Now the accents in the comments of my pictures and albums appeared as question marks.  The data stored in the database was in latin-1.

I then proceeded to convert the mysqldump from latin-1 to utf-8
Code: [Select]
iconv --output cpb-utf8.sql -f latin1 -tutf-8 cpg.sql
I imported the database into mysql
Code: [Select]
mysql -uUser -pPass database < cpg-utf8.sql
I received a fatal error.  The database had been overwritten with the 1.3.X database.  I executed again update.php and it worked correctly

My charset is now UTF-8, and my accents are displayed correctly.

Result in http://andreso.net/galeria
Logged
Pages: [1]   Go Up
 

Page created in 0.016 seconds with 19 queries.