Solved

UTF-8 chars in html

Posted on 2014-02-07
4
333 Views
Last Modified: 2014-03-09
Hello experts

I have a php page containing html
Everything was ok until i noticed that database echo's where not displaying there utf-8 chars.
I added the following to the file
<!DOCTYPE html>
<meta charset="utf-8">

This solved the displaying of the utf-8 chars from the database echo's
But now the utf-8 chars that are in the html of that page like € and é ë are displayed as <?> icons

Any id's?
0
Comment
Question by:Th0R
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
4 Comments
 
LVL 110

Accepted Solution

by:
Ray Paseur earned 500 total points
ID: 39843105
It's a common issue.

Please read this article and post back if you still have any questions.
http://www.experts-exchange.com/Web_Development/Web_Languages-Standards/PHP/A_11880-Unicode-PHP-and-Character-Collisions.html

Best regards, ~Ray
0
 
LVL 15

Expert Comment

by:StealthyDev
ID: 39844346
Hi,

Since they are static content, try encoding the characters in your HTML page using the below table.

http://www.utf8-chartable.de/unicode-utf8-table.pl?utf8=oct&unicodeinhtml=dec&htmlent=1
0

Featured Post

Free Tool: Path Explorer

An intuitive utility to help find the CSS path to UI elements on a webpage. These paths are used frequently in a variety of front-end development and QA automation tasks.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
Form submit takes only for one form 23 54
Checkbox changes display when resizing window 8 26
integrated two Separate file . 3 30
Can't Find The Code 15 21
This article discusses four methods for overlaying images in a container on a web page
Many old projects have bad code, but the budget doesn't exist to rewrite the codebase. You can update this code to be safer by introducing contemporary input validation, sanitation, and safer database queries.
In this tutorial viewers will learn how to style elements, such a divs, with a "drop shadow" effect using the CSS box-shadow property Start with a normal styled element, such as a div.: In the element's style, type the box shadow property: "box-shad…
The viewer will learn the benefit of using external CSS files and the relationship between class and ID selectors. Create your external css file by saving it as style.css then set up your style tags: (CODE) Reference the nav tag and set your prop…

751 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question