delphi programming forums mysql charset mget recursive synonimos
free ventrilo servers hosting cs javascript delay python find in list
Back Forum New
abstract:

my problem is, i dono how to include css in tat email.
how should i do tat?


hi, in my site i got a "tell a friend" section, where user can tell their friends about my site. and then i will send out an email to their friends.
my problem is, i dono how to include css in tat email.
how should i do tat?

TOP

Just stick it in the <head> section.

TOP

err...something like this??
mail($mesg, $subject, $headers...
part of my css:
Code:
  1. body {
  2.         background-color: #fffcfc;
  3.         scrollbar-face-color: #f7eeee;
  4.         scrollbar-highlight-color: #FFFFFF;
  5.         scrollbar-shadow-color: #f7eeee;
  6.         scrollbar-3dlight-color: #F5E9E9;
  7.         scrollbar-arrow-color:  #800000;
  8.         scrollbar-track-color: #fbf5f5;
  9.         scrollbar-darkshadow-color: #cc9999;
  10. }
Copy Code
put in part of the message:
PHP Code:
$mesg
.=
"body {"
;
$mesg
.=
"background-color: #fffcfc;"
;
$mesg
.=
"scrollbar-face-color: #f7eeee;"
;
$mesg
.=
"scrollbar-highlight-color: #FFFFFF;"
;
$mesg
.=
"scrollbar-shadow-color: #f7eeee;"
;
$mesg
.=
"scrollbar-3dlight-color: #F5E9E9;"
;
$mesg
.=
"scrollbar-arrow-color:  #800000;"
;
$mesg
.=
"scrollbar-track-color: #fbf5f5;"
;
$mesg
.=
"scrollbar-darkshadow-color: #cc9999;"
;
$mesg
.=
"}"
;
and send it out??

TOP

As I said before, stick it in <head>
PHP Code:
$msg
=<<<html
<html><head><style>
body
{
    background-color: #fffcfc;
    scrollbar-face-color: #f7eeee;
    scrollbar-highlight-color: #FFFFFF;
    scrollbar-shadow-color: #f7eeee;
    scrollbar-3dlight-color: #F5E9E9;
    scrollbar-arrow-color:  #800000;
    scrollbar-track-color: #fbf5f5;
    scrollbar-darkshadow-color: #cc9999;
}
</style></head><body>blah blah</body></html>
html;

TOP

abstract:

my problem is, i dono how to include css in tat email.
how should i do tat?


i tried u way u show me..but the style still now showing up in my email. wat is wrong?
is it because the email i sent to got it's own style and my style cannot overwrite the email style...for eg hotmail??

TOP

I don't think you'll get the scrollbar things (which btw are non-standard) to work in your e-mail prog, since those are meant for IE only. One reason for not using them...

TOP

To use HTML/styles in an e-mail it's got to be sent with the appopriate MIME type.



my problem is, i dono how to include css in tat email.
how should i do tat?

TOP

Back Forum