Re: [PHP] css in mail()

2007-02-23 Thread Richard Lynch
On Wed, February 21, 2007 3:46 am, Sancar Saran wrote:
 Hi,
 Actual was this

 !DOCTYPE html PUBLIC -//W3C//DTD XHTML 1.0 Transitional//EN
  http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd;
 html
  head
  meta http-equiv=content-type content=text/html; charset=utf-8 /
  meta name=description content= /
  meta name=keywords content= /
  titleTitle/title
  /head
  style type=apstext/cssaps
 ...

It's entirely possible the PHP 'mail' command now adds the various
MIME headers and whatnot to make this work, but it sure didn't used
to...

Or maybe they went and simplified the whole MIME mess since I last
looked and now you don't need those 'boundary' things to get a valid
HTML email.

You still have the issue of spam filters catching it as HTML email, so
losing audience share to that

I know I see a TON of email that starts off with html in the actual
email.  Actually, I don't really see it, as I hit 'delete'
automatically at that point.

-- 
Some people have a gift link here.
Know what I want?
I want you to buy a CD from some starving artist.
http://cdbaby.com/browse/from/lynch
Yeah, I get a buck. So?

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] css in mail()

2007-02-21 Thread Sancar Saran
Hi,
Actual was this

!DOCTYPE html PUBLIC -//W3C//DTD XHTML 1.0 Transitional//EN
 http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd;
html
 head
 meta http-equiv=content-type content=text/html; charset=utf-8 /
 meta name=description content= /
 meta name=keywords content= /
 titleTitle/title
 /head
 style type=apstext/cssaps
...

Those code was example.


On Wednesday 21 February 2007 06:39, Peter Lauri wrote:
 If you are just using the code snippet below you will probably get problems
 in Outlook and some other clients. This because you haven't set the proper
 header.

 But I actually need to assume you did send with a more sophisticated
 version. Otherwise KMAIL probably displayed it incorrectly as well.

 Best regards,

 Best regards,
 Peter Lauri

 www.dwsasia.com - company web site
 www.lauri.se - personal web site
 www.carbonfree.org.uk - become Carbon Free


 -Original Message-
 From: Sancar Saran [mailto:[EMAIL PROTECTED]
 Sent: Wednesday, February 21, 2007 3:02 AM
 To: [EMAIL PROTECTED]
 Cc: php-general@lists.php.net
 Subject: Re: [PHP] css in mail()

 Hi,

 On Wednesday 21 February 2007 01:14, Richard Lynch wrote:
  On Mon, February 19, 2007 10:56 am, Sancar Saran wrote:
   On Monday 19 February 2007 17:03, Danial Rahmanzadeh wrote:
   how can i use css with mail()?
   thank u
  
   ?php
   $data ='';
   $fp = fopen (site/themes/.$arrStat['theme']./css/main.css,r);
   while (!feof($fp)) { $data.= fgets($fp, 16384); }
  
   $mail=
   html
   head
 titleTitle/title
 style.$data./style
   /head
   body
   Html content
   /body
   /html;
  
   mail('[EMAIL PROTECTED]', 'You are welcome', $mail);
   ?
 
  No.
 
  This will only work on very badly-broken email clients.

 Really ?
 I did not have to much choices to check it, In KMAIL everything looks nice.

 Thanks for info

  I believe, in fact, that the only email client broken enough for this
  to work is Outlook.
 
  Though I suspect some very lame web-based email client might actually
  work, come to think of it.

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] css in mail()

2007-02-20 Thread Fergus Gibson
Sancar Saran wrote:
 $mail=
 html
 head
   titleTitle/title
   style.$data./style
 /head
 body
 Html content
 /body
 /html;

I stopped being a designer quite a long time ago, and I never learned
how to compose HTML e-mail because I think it's a blight.  I do,
however, work with some talented designers, and they (and Google) tell
me that the above is basically a terrible idea.

Apparently e-mail clients do not support properly formed HTML very well.
 It is suggested not to use html/html tags or a head/head (most
clients apparently strip the HTML header).  The CSS should be inclined
in the body, as wrong as that is in HTML/XHTML.

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] css in mail()

2007-02-20 Thread Richard Lynch
On Mon, February 19, 2007 9:03 am, Danial Rahmanzadeh wrote:
 how can i use css with mail()?
 thank u

Don't.

HTML enhanced (cough, cough) email is used predominantly by spammers,
so if you do this, you'll be back here in a few days/weeks/months
asking what you can do to get your email to get through all the spam
filters, and we'll just tell you to stop doing HTML-enhanced email.

So let's save you, and us, a month-long debacle here, okay?

If you absolutely positively cannot convince the client to not use
HTML enhanced email, the MIME email class on http://phpclasses.org
will take care of the grungy details, or you could use the PEAR class
for this or you could Google for PHP MIME email and find a few
zillion pages.

-- 
Some people have a gift link here.
Know what I want?
I want you to buy a CD from some starving artist.
http://cdbaby.com/browse/from/lynch
Yeah, I get a buck. So?

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] css in mail()

2007-02-20 Thread Richard Lynch
On Mon, February 19, 2007 10:56 am, Sancar Saran wrote:
 On Monday 19 February 2007 17:03, Danial Rahmanzadeh wrote:
 how can i use css with mail()?
 thank u

 ?php
 $data ='';
 $fp = fopen (site/themes/.$arrStat['theme']./css/main.css,r);
 while (!feof($fp)) { $data.= fgets($fp, 16384); }

 $mail=
 html
 head
   titleTitle/title
   style.$data./style
 /head
 body
 Html content
 /body
 /html;

 mail('[EMAIL PROTECTED]', 'You are welcome', $mail);
 ?

No.

This will only work on very badly-broken email clients.

I believe, in fact, that the only email client broken enough for this
to work is Outlook.

Though I suspect some very lame web-based email client might actually
work, come to think of it.

-- 
Some people have a gift link here.
Know what I want?
I want you to buy a CD from some starving artist.
http://cdbaby.com/browse/from/lynch
Yeah, I get a buck. So?

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] css in mail()

2007-02-20 Thread Sancar Saran
Hi,
On Wednesday 21 February 2007 01:14, Richard Lynch wrote:
 On Mon, February 19, 2007 10:56 am, Sancar Saran wrote:
  On Monday 19 February 2007 17:03, Danial Rahmanzadeh wrote:
  how can i use css with mail()?
  thank u
 
  ?php
  $data ='';
  $fp = fopen (site/themes/.$arrStat['theme']./css/main.css,r);
  while (!feof($fp)) { $data.= fgets($fp, 16384); }
 
  $mail=
  html
  head
  titleTitle/title
  style.$data./style
  /head
  body
  Html content
  /body
  /html;
 
  mail('[EMAIL PROTECTED]', 'You are welcome', $mail);
  ?

 No.

 This will only work on very badly-broken email clients.
Really ?
I did not have to much choices to check it, In KMAIL everything looks nice.

Thanks for info
 I believe, in fact, that the only email client broken enough for this
 to work is Outlook.

 Though I suspect some very lame web-based email client might actually
 work, come to think of it.

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



RE: [PHP] css in mail()

2007-02-20 Thread Peter Lauri
If you are just using the code snippet below you will probably get problems
in Outlook and some other clients. This because you haven't set the proper
header.

But I actually need to assume you did send with a more sophisticated
version. Otherwise KMAIL probably displayed it incorrectly as well.

Best regards,

Best regards,
Peter Lauri

www.dwsasia.com - company web site
www.lauri.se - personal web site
www.carbonfree.org.uk - become Carbon Free


-Original Message-
From: Sancar Saran [mailto:[EMAIL PROTECTED] 
Sent: Wednesday, February 21, 2007 3:02 AM
To: [EMAIL PROTECTED]
Cc: php-general@lists.php.net
Subject: Re: [PHP] css in mail()

Hi,
On Wednesday 21 February 2007 01:14, Richard Lynch wrote:
 On Mon, February 19, 2007 10:56 am, Sancar Saran wrote:
  On Monday 19 February 2007 17:03, Danial Rahmanzadeh wrote:
  how can i use css with mail()?
  thank u
 
  ?php
  $data ='';
  $fp = fopen (site/themes/.$arrStat['theme']./css/main.css,r);
  while (!feof($fp)) { $data.= fgets($fp, 16384); }
 
  $mail=
  html
  head
  titleTitle/title
  style.$data./style
  /head
  body
  Html content
  /body
  /html;
 
  mail('[EMAIL PROTECTED]', 'You are welcome', $mail);
  ?

 No.

 This will only work on very badly-broken email clients.
Really ?
I did not have to much choices to check it, In KMAIL everything looks nice.

Thanks for info
 I believe, in fact, that the only email client broken enough for this
 to work is Outlook.

 Though I suspect some very lame web-based email client might actually
 work, come to think of it.

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP] css in mail()

2007-02-19 Thread Danial Rahmanzadeh

how can i use css with mail()?
thank u


Re: [PHP] css in mail()

2007-02-19 Thread Jochem Maas
Danial Rahmanzadeh wrote:
 how can i use css with mail()?

this kind of question is really annoying [today] - it shows that you are
a f***ing lazy b'std who can't even be bothered to formulate a question
properly let alone type something like 'CSS mail php' into the nearest
search engine.

we are not here to do your job for you.**

please STFW and go find yourself a tutorial/clue/code-snippet
related to sending HTML email [using php].

**suppressing the desire to rant along the lines of my job went to India
and now I'm relegated to spoon feeding the answers to the moron, who has been
programming for all of 3 days but *is* getting paid for the work I'm still 
doing,
for free

 thank u
 

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] css in mail()

2007-02-19 Thread Sancar Saran
On Monday 19 February 2007 17:03, Danial Rahmanzadeh wrote:
 how can i use css with mail()?
 thank u

?php
$data ='';
$fp = fopen (site/themes/.$arrStat['theme']./css/main.css,r);
while (!feof($fp)) { $data.= fgets($fp, 16384); }

$mail=
html
head
titleTitle/title
style.$data./style
/head
body
Html content
/body
/html;

mail('[EMAIL PROTECTED]', 'You are welcome', $mail);
?

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] css in mail()

2007-02-19 Thread tedd

At 4:38 PM +0100 2/19/07, Jochem Maas wrote:

Danial Rahmanzadeh wrote:

 how can i use css with mail()?


this kind of question is really annoying [today] - it shows that you are
a f***ing lazy b'std who can't even be bothered to formulate a question
properly let alone type something like 'CSS mail php' into the nearest
search engine.

we are not here to do your job for you.**

please STFW and go find yourself a tutorial/clue/code-snippet
related to sending HTML email [using php].

**suppressing the desire to rant along the lines of my job went to India
and now I'm relegated to spoon feeding the answers to the moron, who has been
programming for all of 3 days but *is* getting paid for the work I'm 
still doing,

for free


Jochem:

Well... I see no reason to sugar-coat your reply. Tell him what you 
really think. :-)


tedd
--
---
http://sperling.com  http://ancientstones.com  http://earthstones.com

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php