how to create utf-8 unicodeded txt file with php?
Moderator: General Moderators
how to create utf-8 unicodeded txt file with php?
how to create utf-8 unicodeded txt file with php?
Use
Code: Select all
<?
header("Content-type: text/plain;charset=utf-8 \r\n");
header("Content-Disposition: attachment; filename=text.txt");
echo "text file content";
?>- Kieran Huggins
- DevNet Master
- Posts: 3635
- Joined: Wed Dec 06, 2006 4:14 pm
- Location: Toronto, Canada
- Contact:
also take a look at http://www.php.net/manual/en/ref.mbstring.php
There's no sense in sending a UTF-8 doc if it's not full of UTF-8 content
There's no sense in sending a UTF-8 doc if it's not full of UTF-8 content
- Ollie Saunders
- DevNet Master
- Posts: 3179
- Joined: Tue May 24, 2005 6:01 pm
- Location: UK