0

I have hopefully an easily resolved problem.

I have set up a test php page on my sever with the following code:

<?php

header('Content-Type: text/html; charset=utf-8');

echo "£";

?>

However when I re-open the file to edit the symbol 'Ã' is appended to the £ symbol. An additional 'Ã' is appended each time I open the script.

<?php

header('Content-Type: text/html; charset=utf-8');

echo "£";

?>

How do I prevent this from happening?

MattBlack
  • 3,616
  • 7
  • 32
  • 58
  • 3
    This has nothing to do with php, html or http. It simply is a question of your local systems setup. Obviously the editor uses different encodings. You should first take care to reconfigure your local system such that it actually uses UTF-8. That is nothing you can somehow reach by php code or a header entry. – arkascha Mar 09 '17 at 11:48
  • Possible duplicate of [UTF-8 all the way through](http://stackoverflow.com/questions/279170/utf-8-all-the-way-through) – domsson Mar 09 '17 at 12:25

0 Answers0