Reputation: 7906
I have code like
<?php
header('Content-Type: text/plain; charset=UTF-8');
echo 'Hello Loréane !';
the e character is not printed properly. How should i fix the code without removing or altering exiting lines of code ?
This is what i get in browser
Hello Lor�ane !
Upvotes: 2
Views: 479
Reputation: 2025
Check if your file in encoding utf-8 and add
<meta charset="utf-8" />
into your head tags.
Upvotes: 1
Reputation: 449395
Make sure your PHP source file is encoded as UTF-8. It is probably encoded als Windows-1252 or ISO-8859-1.
Upvotes: 2