character encoding

This is a discussion on character encoding within the PHP General forums, part of the PHP Programming Forums category; Hi LAMP A column in a table has" Brébeuf " in it. (3rd caracter is é) I ...


Go Back   Usenet Forums > PHP Programming Forums > PHP General

FAQ Members List Calendar Search Today's Posts Mark Forums Read
  #1 (permalink)  
Old 03-26-2008
Bill
 
Posts: n/a
Default character encoding

Hi

LAMP

A column in a table has" Brébeuf " in it. (3rd caracter is é)

I use that table to send emails.

In the body that column shows " Brébeuf " in Windows Outlook.

How could I translate to the correct encoding so that accents show correctly
in Outlook ?

Thanks



Reply With Quote
  #2 (permalink)  
Old 03-26-2008
Zoltán Németh
 
Posts: n/a
Default Re: [PHP] character encoding

2008. 03. 26, szerda keltezéssel 15.57-kor Bill ezt Ã*rta:
> Hi
>
> LAMP
>
> A column in a table has" Brbeuf " in it. (3rd caracter is é)
>
> I use that table to send emails.
>
> In the body that column shows " Brébeuf " in Windows Outlook.
>
> How could I translate to the correct encoding so that accents show correctly
> in Outlook ?


based on the encoding of your e-mail, my guess is that your data is in
some ISO-8859-1 encoding or something like that. of course, you should
verify that first.
so try to send those emails with that encoding, or what's much better,
use utf8 for both your data and your email. I think outlook can cope
with that, though I'm not sure ;)

greets,
Zoltán Németh


>
> Thanks
>
>
>
>


Reply With Quote
  #3 (permalink)  
Old 03-26-2008
Bill
 
Posts: n/a
Default Re: [PHP] character encoding

Hi Zoltan,

>> A column in a table has" Brbeuf " in it. (3rd caracter is é)
>> In the body that column shows " Brébeuf " in Windows Outlook.
>>
>> How could I translate to the correct encoding so that accents show
>> correctly
>> in Outlook ?

>
> based on the encoding of your e-mail, my guess is that your data is in
> some ISO-8859-1 encoding or something like that. of course, you should
> verify that first.
> so try to send those emails with that encoding, or what's much better,
> use utf8 for both your data and your email. I think outlook can cope
> with that, though I'm not sure ;)


The encoding can be set to utf-8 in the recieved email, what translates the
encoding but the sender's outlook window doesn't.

It's a site where you can ask the owner to upgrade your account limit by
clicking on a mailto link who writes most of the email body. The data used
is your record from a Mysql table.

When you use that link it opens a email window and the body of that message
isn't translated. So the people will see some garbage and may not send the
email.

If I try to change the encoding in the editing window of Outlook while this
garbaged email shows it doesn't work. I still see the garbage, yet my
outlook is set for utf-8 !!

Bill


Reply With Quote
  #4 (permalink)  
Old 03-26-2008
Zoltán Németh
 
Posts: n/a
Default Re: [PHP] character encoding

2008. 03. 26, szerda keltezéssel 18.04-kor Bill ezt Ã*rta:
> Hi Zoltan,
>
> >> A column in a table has" Brbeuf " in it. (3rd caracter is é)
> >> In the body that column shows " Brbeuf " in Windows Outlook.
> >>
> >> How could I translate to the correct encoding so that accents show
> >> correctly
> >> in Outlook ?

> >
> > based on the encoding of your e-mail, my guess is that your data is in
> > some ISO-8859-1 encoding or something like that. of course, you should
> > verify that first.
> > so try to send those emails with that encoding, or what's much better,
> > use utf8 for both your data and your email. I think outlook can cope
> > with that, though I'm not sure ;)

>
> The encoding can be set to utf-8 in the recieved email, what translates the
> encoding but the sender's outlook window doesn't.
>
> It's a site where you can ask the owner to upgrade your account limit by
> clicking on a mailto link who writes most of the email body. The data used
> is your record from a Mysql table.



> When you use that link it opens a email window and the body of that message
> isn't translated. So the people will see some garbage and may not send the
> email.
>
> If I try to change the encoding in the editing window of Outlook while this
> garbaged email shows it doesn't work. I still see the garbage, yet my
> outlook is set for utf-8 !!


then change the collation of that table to utf8 and store all data in
utf8

greets
Zoltán Németh

>
> Bill
>
>
>


Reply With Quote
  #5 (permalink)  
Old 03-27-2008
Manuel Lemos
 
Posts: n/a
Default Re: character encoding

Hello,

on 03/26/2008 04:57 PM Bill said the following:
> A column in a table has" Brébeuf " in it. (3rd caracter is é)
>
> I use that table to send emails.
>
> In the body that column shows " Brébeuf " in Windows Outlook.
>
> How could I translate to the correct encoding so that accents show correctly
> in Outlook ?


You should not send 8 bit data in your messages without proper quoted
printable encoding. Also you need to specify the character set of text
you are sending.

You may want to try this MIME message composing and sending class that
supports quoted printable encoding with any character set either in the
text and in the message body.

Take a look test_email_message.php for single by character sets or even
the test_multibyte_message.php if you are not using multibyte character
sets.

http://www.phpclasses.org/mimemessage

--

Regards,
Manuel Lemos

PHP professionals looking for PHP jobs
http://www.phpclasses.org/professionals/

PHP Classes - Free ready to use OOP components written in PHP
http://www.phpclasses.org/
Reply With Quote
  #6 (permalink)  
Old 03-28-2008
Bill
 
Posts: n/a
Default Re: character encoding

Hi Manuel

>> In the body that column shows " Brébeuf " in Windows Outlook.


> You may want to try this MIME message composing and sending class that
> http://www.phpclasses.org/mimemessage


Looks great Manuel.but my server is under dyndns and the DN isn't qualified
so no mail functions available.

I was asking how to have the right character set translation so the data
stored in the table show no grimmerish in the outlook window.

A simple mailto link in the page with some basic content defined does the
trick but the data retrieved from the table can look awsome in the mail
client before the user sends it back to the owner email address.

I'm making a site for myself. I'm a paintbrush artist, among other things,
and I've set a buying level for the visitors. But one can ask to raise his
level so he can buy more things in one session.
For that I use a mailto link sent to my hotmail with the request giving the
name and address of the sender. And that's where I can't control anything.
The guy may have written accented caracters in his record and when that info
is brought back, it messes the Outlook msg window of the sender.

Can I force Outlook msg composer to use my Mysql table collation ?

Thanks


Reply With Quote
  #7 (permalink)  
Old 03-28-2008
Manuel Lemos
 
Posts: n/a
Default Re: character encoding

Hello,

on 03/28/2008 12:08 PM Bill said the following:
> Hi Manuel
>
>>> In the body that column shows " Brébeuf " in Windows Outlook.

>
>> You may want to try this MIME message composing and sending class that
>> http://www.phpclasses.org/mimemessage

>
> Looks great Manuel.but my server is under dyndns and the DN isn't

qualified
> so no mail functions available.


I am not sure what you mean. This class can compose messages which can
be delivered by different drivers, like the mail() function, SMTP
client, qmail, sendmail, etc. If you can't use the mail function, you
can still send message relaying them through an SMTP server, like for
instance Gmail's.


> I was asking how to have the right character set translation so the data
> stored in the table show no grimmerish in the outlook window.
>
> A simple mailto link in the page with some basic content defined does the
> trick but the data retrieved from the table can look awsome in the mail
> client before the user sends it back to the owner email address.
>
> I'm making a site for myself. I'm a paintbrush artist, among other

things,
> and I've set a buying level for the visitors. But one can ask to raise

his
> level so he can buy more things in one session.
> For that I use a mailto link sent to my hotmail with the request

giving the
> name and address of the sender. And that's where I can't control

anything.
> The guy may have written accented caracters in his record and when

that info
> is brought back, it messes the Outlook msg window of the sender.
>
> Can I force Outlook msg composer to use my Mysql table collation ?


You can build mailto: links with a default subject and text, but I am
not sure you can force Outlook to use specific HTML. It's wiser to not
rely on mailto: .

--

Regards,
Manuel Lemos

PHP professionals looking for PHP jobs
http://www.phpclasses.org/professionals/

PHP Classes - Free ready to use OOP components written in PHP
http://www.phpclasses.org/
Reply With Quote
  #8 (permalink)  
Old 03-29-2008
Bill
 
Posts: n/a
Default Re: character encoding

Hi Manuel


> You can build mailto: links with a default subject and text, but I am
> not sure you can force Outlook to use specific HTML. It's wiser to not
> rely on mailto: .


Hotmail will accept mail delivery from PHP ?




Reply With Quote
  #9 (permalink)  
Old 03-29-2008
Colin Guthrie
 
Posts: n/a
Default Re: character encoding

Bill wrote:
>> You can build mailto: links with a default subject and text, but I am
>> not sure you can force Outlook to use specific HTML. It's wiser to not
>> rely on mailto: .

>
> Hotmail will accept mail delivery from PHP ?


mailto: links have nothing to do with PHP but generally speaking mailto:
is not compatible with webmail unless you have some sort of
extension/url handler installed.


Reply With Quote
  #10 (permalink)  
Old 03-29-2008
Manuel Lemos
 
Posts: n/a
Default Re: character encoding

Hello,

on 03/29/2008 12:43 PM Bill said the following:
>> You can build mailto: links with a default subject and text, but I am
>> not sure you can force Outlook to use specific HTML. It's wiser to not
>> rely on mailto: .

>
> Hotmail will accept mail delivery from PHP ?


Sure. There is nothing specific of PHP that prevents Hotmail from
accepting messages sent by PHP scripts.

--

Regards,
Manuel Lemos

PHP professionals looking for PHP jobs
http://www.phpclasses.org/professionals/

PHP Classes - Free ready to use OOP components written in PHP
http://www.phpclasses.org/
Reply With Quote
Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are Off
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On



All times are GMT +1. The time now is 08:06 AM.


Powered by vBulletin® Version 3.7.3
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO 3.0.0