ohboyatoytruck Posted January 8, 2015 Share Posted January 8, 2015 Hi there, I am getting this in a PHP generated email: ACWA Member/Subscriber: Melody’s Children’s Service The line of code in the php is: $subject = "ACWA Member/Subscriber: $membername"; I have tried htmlentitiies, html_entity_decode, htmlspecialchars but nothing seems to work. I haven't used htmlentities anywhere else in the code for this variable. Any suggestions? All advice gratefully received. Quote Link to comment Share on other sites More sharing options...
requinix Posted January 8, 2015 Share Posted January 8, 2015 And how about the rest of your code? Quote Link to comment Share on other sites More sharing options...
hansford Posted January 8, 2015 Share Posted January 8, 2015 And is the data coming from the database. Character corruption. Quote Link to comment Share on other sites More sharing options...
ohboyatoytruck Posted January 13, 2015 Author Share Posted January 13, 2015 Yep the data is coming from the database but it looks fine in there and if I copy and paste it into Word it still looks fine. In the Export Data dialog in the database, there are character set options as follows: Windows (ANSI) ASCII (DOS) Macintosh Unicode (UTF-16) Unicode (UTF- <--- this is currently selected. Quote Link to comment Share on other sites More sharing options...
ohboyatoytruck Posted January 13, 2015 Author Share Posted January 13, 2015 And how about the rest of your code? Rest of the code is good but there are no other instances of apostrophes so not sure if that helps much. Quote Link to comment Share on other sites More sharing options...
requinix Posted January 13, 2015 Share Posted January 13, 2015 I'll rephrase: How about posting the rest of your code? 1 Quote Link to comment Share on other sites More sharing options...
hansford Posted January 15, 2015 Share Posted January 15, 2015 Requinix is right - post the rest of the code. And is the charset set to match the chars in the database. Content-Type: text/html; charset=utf-8 Quote Link to comment Share on other sites More sharing options...
ohboyatoytruck Posted January 15, 2015 Author Share Posted January 15, 2015 Requinix is right - post the rest of the code. And is the charset set to match the chars in the database. Content-Type: text/html; charset=utf-8 yep its utf-8 on the page Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.