corsasport.co.uk
 

Corsa Sport » Message Board » Off Day » Geek Day » PHP and certain characters...


New Topic

New Poll
  Subscribe | Add to Favourites

You are not logged in and may not post or reply to messages. Please log in or create a new account or mail us about fixing an existing one - register@corsasport.co.uk

There are also many more features available when you are logged in such as private messages, buddy list, location services, post search and more.


Author PHP and certain characters...
ed
Member

Registered: 10th Sep 03
User status: Offline
20th Nov 06 at 22:47   View User's Profile U2U Member Reply With Quote

When sending an e-mail through my mail script I recently wrote I have noticed that some of the characters don't come up correctly. For example the £ symbol comes up as a ? . Does anyone know of a way around this. I am already using strip_slashes() to sort out the \ thing PHP does the arguments sent to mail(), but is there another thing needed to sort this problem?
Ian
Site Administrator

Avatar

Registered: 28th Aug 99
Location: Liverpool
User status: Offline
21st Nov 06 at 00:22   View Garage View User's Profile U2U Member Reply With Quote

Something to do with the character sets, try chr function, £ sign being 163.

http://uk2.php.net/chr
ed
Member

Registered: 10th Sep 03
User status: Offline
21st Nov 06 at 00:28   View User's Profile U2U Member Reply With Quote

The problem is this is a script which the user types in a message into a form and it e-mails that message to the whole group using send(). I guess I could write a script that used that function though. If they were set messages then it would be easier...
AndyKent
Member

Registered: 3rd Sep 05
User status: Offline
21st Nov 06 at 13:41   View User's Profile U2U Member Reply With Quote

IIRC, search google for 'htmlentites' - should convert problem characters to their HTML version (ie. £ to £ )
MikeLamb
Member

Registered: 23rd Sep 03
Location: Crowthorne Drives: Veccy SRI
User status: Offline
21st Nov 06 at 19:23   View User's Profile U2U Member Reply With Quote

you need to add something like "text/plain; charset=iso-8859-1" to the content-type header

 
New Topic

New Poll

  Related Threads Author Forum Replies Views Last Post
Needed - 6 cartoon characters. Tiger General Chat 3 141
19th Sep 03 at 20:11
by Tiger
 
bbc 1 tonite (crail) vaux_red_corsa General Chat 2 135
23rd Mar 04 at 21:16
by vaux_red_corsa
 
Annoying search engine redirects - HELP!! Sam Geek Day 6 159
2nd Dec 05 at 16:30
by Sam
 

Corsa Sport » Message Board » Off Day » Geek Day » PHP and certain characters... 28 database queries in 0.0146570 seconds