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 9003021
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 16, 20262026-06-16T00:39:28+00:00 2026-06-16T00:39:28+00:00

There’s an UTF8 problem on my site which I can’t solve (nor understand). When

  • 0

There’s an UTF8 problem on my site which I can’t solve (nor understand).
When I use…

$mysqli->set_charset('utf8');

… on my webspace, then special chars are displayed incorrectly. When I delete this function, then all special chars from database queries are displayed correctly. On my local system it’s the opposite (without set_charset(‘utf8’) the chars are not displayed in proper manner)

I also made a test script to see if this is a problem of my webhost. The test works correct on my webspace and locally.

<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<?php
$db = new mysqli( bla bla );
$db->set_charset('utf8');
$sql  = "SELECT pages_title
         FROM pages
         WHERE pages_title = 'Günstige Tablet PCs'";
$result = $db->prepare( $sql );
$result->execute();
$result->bind_result( $title );
$result->store_result();
$result->fetch();
$result->free_result(); 

echo "Title: ". $title;

Now I’m running out of ideas where the problem could be. Everything is set right:

  1. The database itself is set to utf8-general-ci
  2. Files are formatted in UTF8.
  3. <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> is set.

Because the test script is running correctly the problem should be within my code, but I got no idea what could cause the error, because I’m not doing anything with utf8_encode/decode or something like that.

Any ideas?? Thanks!!

  • 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-06-16T00:39:29+00:00Added an answer on June 16, 2026 at 12:39 am

    try out this, should solve it.

    <?php header('Content-Type: text/html; charset=UTF-8'); ?>
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

There's a Rails 3.2.3 web application which doesn't use any database. But in spite
I am trying to understand how to use SyndicationItem to display feed which is
there can be two productions from which we can do the reduction. After giving
There is something I can't understand about Common lisp. Assume I'm writing a macro
There is a directed graph having a single designated node called root from which
There are two intents on the receiver side which are called from the same
There is some unknown problem with my facebook app running on heroku Problem is
There can only be one IDENTITY column per table Why is it so? Take
There's no Sort() function for IList . Can someoene help me with this? I
There are two tables: aspnet_users and aspnet_membership. Can anyone elaborate on the reasons why

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.