Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 1003221
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 16, 20262026-05-16T07:56:48+00:00 2026-05-16T07:56:48+00:00

I am using $encoding = ‘utf-8’; in gettext and in my html code i

  • 0

I am using $encoding = 'utf-8'; in gettext and in my html code i have set <meta charset="utf-8">. I have also set utf-8 in my .po files, but I still get � when I write æøå! What can be wrong?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-16T07:56:48+00:00Added an answer on May 16, 2026 at 7:56 am

    Let’s see how the values you mention are at the byte level.

    I copied the æøå from your question and � from your title. The reason for � is that I had to use a Windows console application to fetch the title of your question and its codepage was Windows 1252 (copying from the browser gave me Unicode Character 'REPLACEMENT CHARACTER' (U+FFFD)).

    In a script encoded in UTF-8, this gives:

    <?php
    $s = 'æøå';
    $s2 = '�';
    
    echo "s iso-8859-1 ", @reset(unpack("H*", mb_convert_encoding($s, "ISO-8859-1", "UTF-8"))), "\n";
    echo "s2 win-1252  ", @reset(unpack("H*", mb_convert_encoding($s, "WINDOWS-1252", "UTF-8"))), "\n";
    
    s iso-8859-1 e6f8e5
    s2 win-1252  e6f8e5
    

    So the byte representation matches. The problem here is that when you write æøå either:

    • You’re writing it in ISO-8859-1, instead of UTF-8. Check your text editor.
    • The value is being converted from UTF-8 to ISO-8859-1 (unlikely)
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I converted all my files to UTF-8 without BOM encoding using Notepad++. I have
If I'm using utf-8 encoding for a character set that would use the character
Encoding using UTF-8. ( Multiple languages in one HTML page ). What are the
I have a large url that I am encoding using System.Web.HttpUtility.UrlEncode. When I encode
I have the following text: We%27re%20proud%20to%20introduce%20the%20Amazing I'd like to remove the encoding using PHP,
I am dealing with some unicode strings, which I am encoding using utf-8 whenever
The IETF recommends using base64 encoding for binary cookie values: https://datatracker.ietf.org/doc/html/draft-ietf-httpstate-cookie-07 So I use
I have a Windows/Apache2/PHP app that receives file using chunked encoding. The reason is
I saved my Java source file specifying it's encoding type as UTF-8 (using Notepad,
Lets say I want to set up a basic text encoding using a dictionary

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.