Jump to content


Corporate Sponsors


Latest News: (loading..)

- - - - -

Wrong letters on buttons at code utf8


  • You cannot reply to this topic
2 replies to this topic

#1 Matjaz

  • Community Member
  • 3 posts
  • Real Name:Matjaz
  • Gender:Male
  • Location:Slovenia

Posted 11 September 2011, 08:54

I am setting up new store on osc 2.3.1. I have problems with letters of Slovene alphabet on buttons (ADD TO CART ect.).

When I let languages/slovenscina.php in
// charset for web pages and emails define ('CHARSET', 'utf8');
Slovene letters normally appear in products descriptions, it all works very well. But on buttons Slovene letters do not appear properly.

When I change code with
// charset for web pages and emails define ('CHARSET', 'windows-1250');
things change. Then Slovene letters do show on buttons but not in texts, in product descriptions.

Can my problem be solved?

Other setings in this php file I have:

// look in your $PATH_LOCALE/locale directory for available locales
// or type locale -a on the server.
// Examples:
// on RedHat try 'en_US'
// on FreeBSD try 'en_US.ISO_8859-1'
// on Windows try 'sl', or 'slovenscina'
@setlocale(LC_TIME, 'sl_SI.utf8');

#2 MrPhil

  • Community Member
  • 3,294 posts
  • Real Name:Phil
  • Gender:Male

Posted 11 September 2011, 15:37

It sounds like your language file (with the button labels) is not in UTF-8, but Windows-1250 encoding. For English stores, the "Add to Cart" button (IMAGE_BUTTON_IN_CART) is in includes/languages/english.php -- look for the equivalent Slovenian file (slovenscina.php?). You may need to find the correct "-utf8" version, or save it in UTF-8 encoding. My guess is that you or someone else working on the file saved it in the wrong encoding.

#3 Matjaz

  • Community Member
  • 3 posts
  • Real Name:Matjaz
  • Gender:Male
  • Location:Slovenia

Posted 19 September 2011, 12:06

Thank you for your answer. Problem is solved. Whatever I tried in codes Slovene letters did not appear properly.
I solved situation in the way that when translating I have to languages/…php file change in notepad++ separately in UTF-8 without BOM. Just saving translated files directly on server it is not enough.

Best regards,