Back to Top

Problem with German special character

Nowadays I am working on an application in WordPress and got many issues regarding character Encoding especially for German characters like (ä,ü,ë) and the ones that are coming from the database. It happened in all the browsers. I checked my browser and its character Encoding is UTF-8 and those characters are ISO-8859-1 so I have added the meta tag mentioned below:

And also have added the following line in my htaccess file :

After doing that still, the characters have some problem and it doesn’t look proper. I found that ä,ü,ë etc are the ISO-8859-1 so if I change my browser Encoding to ISO-8859-1, it works fine but whenever I change browser to UTF-8 , it doesn’t work.

Finally, I have created one function which converts string for encoding characters and solved the character problems too:

Recommended Read
Clean HTML content in PHP
Convert RGB to Hex HTML code in PHP
Get English Ordinal Number Suffix in PHP

Let’s have a look with one simple example

Thanks for reading this article :). I hope this solution helpful to you. If you have any concern, please share your thoughts on the comment section.

Share:
Share on Facebook0

Share on LinkedIn0Tweet about this on TwitterShare on Google+0Buffer this pageDigg thisShare on Reddit0

Comments (2)

  1. I read many badly wttiren articles these days. This article is a breath of fresh air. It’s nice to see you care about what and how you present your views.

  2. Thanks this function helps me a lot.

    Thanks Again.

Leave a Reply

Your email address will not be published. Required fields are marked *

Most Popular Posts

How to use jQuery Cookie

Posted on 4 years ago

Bhumi

Getting Started with LESS CSS

Posted on 2 years ago

Bhumi

PHP 5 Abstract classes and Methods

Posted on 5 years ago

Bhumi

How to Use the HTML5 Full-Screen API

Updated 17 years ago

Bhumi

What are Lambdas and Closures in PHP?

Updated 17 years ago

Bhumi

MySQL REGEXP Operator

Updated 17 years ago

Bhumi

HTML5 Geolocation API with Example

Updated 17 years ago

Bhumi

Overview of Views in MySQL

Updated 17 years ago

Bhumi

The Reader’s Poll – June 2015

Posted on 2 years ago

Bhumi

The Reader’s Poll – August 2014

Posted on 2 years ago

Bhumi

The Reader’s Poll – June 2014

Posted on 3 years ago

Bhumi

The Readers’ Poll – May 2014

Posted on 3 years ago

Bhumi

The Readers’ Poll – August 2013

Posted on 3 years ago

Bhumi