HighDots Forums  

Style Sheet Question

Cascading Style Sheets Layout/presentation on the WWW (comp.infosystems.www.authoring.stylesheets)


Discuss Style Sheet Question in the Cascading Style Sheets forum.



Reply
 
Thread Tools Display Modes
  #1  
Old   
amerar@iwc.net
 
Posts: n/a

Default Style Sheet Question - 08-09-2005 , 01:18 PM







Hi All,

I can make a page using a style sheet, no problem there. However, if I
make an email and send it out to my list, Yahoo & Hotmail totally
ignore the style tags. It looks fine in Netscape though.....

Question: I've tried linking & embedding the style tags with no luck.
How can I use them inline? I've read that inline style sheets is the
way to go if you want them to work in most email clients.......

Say for example I have the following ID's defined in my style sheet,
how can I use them inlinwe, I'm not sure of the syntax and such:

#idDivBack {
position: absolute;
top: 168px;
left: 150px;
height: 40px;
width: 100%;
background-color: #D0A375; /*#9999CC;*/
border-style: none;
border-width: medium;
font-style: normal;
font-variant: normal;
font-weight: bold;
line-height: 100%;
font-size: 27pt;
font-family: Times, serif;
color: #CC9B6A; /*#8888DD;*/
padding: 5px;
text-align: right;
}
#idDivTitle1a {
position: absolute;
top: 143px;
left: 165px;
height: 100px;
font-style: italic;
font-variant: normal;
font-weight: bold;
line-height: 100%;
font-size: 38pt;
font-family: Verdana, sans-serif;
color: #D0A375; /*#00CC99;*/
background-color: transparent;
filter: shadow(color=#000000, direction=135);
}
#idDivTitle1b {
position: absolute;
top: 140px;
left: 162px;
height: 100px;
font-style: italic;
font-variant: normal;
font-weight: bold;
line-height: 100%;
font-size: 38pt;
font-family: Verdana, sans-serif;
color: #663300; /*blue;*/
background-color: transparent;
}

#idDivTitle2a {
position: absolute;
left: 180px;
top: 193px;
height: 40px;
font-style: normal;
font-variant: normal;
font-weight: bold;
line-height: 100%;
font-size: 24pt;
font-family: Verdana, sans-serif;
color: silver; /*silver;*/
background-color: transparent;
}
#idDivTitle2b {
position: absolute;
left: 190px;
top: 200px;
height: 40px;
font-style: normal;
font-variant: normal;
font-weight: bold;
line-height: 100%;
font-size: 24pt;
font-family: Verdana, sans-serif;
color: #990000; /*navy;*/
background-color: transparent;
}
.BodyArea {
position: absolute;
background-color: #E0E0E0; /*#AAFFEE;*/
color: black;
top: 265px;
width: 680px;
left: 150px;
padding: 5px;
border: medium solid silver; /*#00CC99;*/
margin-bottom: 1cm;
}

@media print {
#idDivBack { visibility: hidden; }
#idDivTitle1a { visibility: hidden; }
#idDivTitle1b { visibility: hidden; }
#idDivTitle2a { visibility: hidden; }
.BodyArea { visibility: hidden; }

#idDivTitle2b {
position: absolute;
left: 150px;
top: 140px;
height: 30px;
font-style: normal;
font-variant: normal;
font-weight: bold;
line-height: 100%;
font-size: 24pt;
font-family: Verdana, sans-serif;
color: #990000; /*navy;*/
background-color: transparent;
}
}


Thanks,

Arthur


Reply With Quote
  #2  
Old   
David Dorward
 
Posts: n/a

Default Re: Style Sheet Question - 08-09-2005 , 01:44 PM






amerar (AT) iwc (DOT) net wrote:

Quote:
I can make a page using a style sheet, no problem there. However, if I
make an email and send it out to my list, Yahoo & Hotmail totally
ignore the style tags.
HTML email is bad.
HTML email with formatting my CSS other then style *attributes* is badly
supported.

Avoid both.

Quote:
Say for example I have the following ID's defined in my style sheet,
how can I use them inlinwe, I'm not sure of the syntax and such:
Change:
id="idDivBack"
to
style="position: absolute;top: 168px;etc etc etc".
and so on.


--
David Dorward <http://blog.dorward.me.uk/> <http://dorward.me.uk/>
Home is where the ~/.bashrc is


Reply With Quote
  #3  
Old   
'sNiek
 
Posts: n/a

Default Re: Style Sheet Question - 08-10-2005 , 03:43 AM



Quote:
Instead you should put all the CSS within the 'style' attribute of the element
you want formatted.

I never use stylsheets in my HTML-mailings. Instead, I use plain old-fashioned HTML (font-tags and such).

So, I wonder: what is the best solution inline CSS or HTML?


Niek


BTW: This is my first post in this newsgroup. I am a sitebuilder from Tilburg, The Netherlands working for www.sebastian.nl


Reply With Quote
  #4  
Old   
Barbara de Zoete
 
Posts: n/a

Default Re: Style Sheet Question - 08-10-2005 , 04:12 AM



On Wed, 10 Aug 2005 09:43:22 +0200, 'sNiek <n.emmen (AT) sebastian (DOT) nl> wrote:

Quote:
I never use stylsheets in my HTML-mailings. Instead, I use plain old-fashioned
HTML (font-tags and such).

So, I wonder: what is the best solution inline CSS or HTML?

Neither. HTML you should use for markup only. Analyse the content you're about
to offer and mark it up with some meaning to it. A heading is a heading, a
paragraph is a paragraph, a list is a list and so on. Once you've done that,
style your pages with CSS using a (external) stylesheet.

The thing about stylesheets is that they make maintenance of a site easy (clean
markup, styles all in the same place). Another benefit is for the visitor: an
external stylesheet gets loaded once and is then used for all pages from a site.
It brings down traffic and loading time. Also, when you want to, the looks of a
site are changed very easily (replace the stylesheet, et voila).

Quote:
BTW: This is my first post in this newsgroup.
Then learn a few things before you post another:
- Don't use HTML; use text only;
- Quote text you reply to, attribute the quote, and reply underneath;
- Delete the text you don't reply to

Quote:
I am a sitebuilder from Tilburg, The Netherlands working for www.sebastian.nl
- And present URLs as such: <http://www.sebastian.nl/> would be the proper URL
for that.

For some more thoughts on this, in Dutch see:
<http://home.wanadoo.nl/b.de.zoete/_private/2004/12/usenet_best_practices.html>
<http://www.hensema.net/docs/quote/quote.html>

in English:
<http://www.spartanicus.utvinternet.ie/help_us_help_you.htm>
<http://groups.google.com/groups?selm=zy9td.29861$Rf1.28448 (AT) newssvr19 (DOT) news.prodigy.com>

And also, you could try the Dutch group some time, niwo:
<http://groups.google.com/group/nl.internet.www.ontwerp>


The page you refer to BTW, is a horror with many mistakes:
<http://validator.w3.org/check?uri=http%3A%2F%2Fwww.sebastian.nl%2Findex.ph p%3Fb%3D1%26d%3D16%26p%3D31>
With all those tables and use of markup attributes for the looks and layout it
is also a horror to maintain.

--
,-- --<--@ -- PretLetters: 'woest wyf', met vele interesses: ----------.
Quote:
weblog | http://home.wanadoo.nl/b.de.zoete/_private/weblog.html |
webontwerp | http://home.wanadoo.nl/b.de.zoete/html/webontwerp.html |
zweefvliegen | http://home.wanadoo.nl/b.de.zoete/html/vliegen.html |
`-------------------------------------------------- --<--@ ------------'



Reply With Quote
  #5  
Old   
Els
 
Posts: n/a

Default Re: Style Sheet Question - 08-10-2005 , 04:14 AM



Barbara de Zoete wrote:

Quote:
On Wed, 10 Aug 2005 09:43:22 +0200, 'sNiek <n.emmen (AT) sebastian (DOT) nl> wrote:

I never use stylsheets in my HTML-mailings. Instead, I use plain old-fashioned
HTML (font-tags and such).

So, I wonder: what is the best solution inline CSS or HTML?

Neither. HTML you should use for markup only. Analyse the content you're about
to offer and mark it up with some meaning to it. A heading is a heading, a
paragraph is a paragraph, a list is a list and so on. Once you've done that,
style your pages with CSS using a (external) stylesheet.
Barbara, Niek is talking about mailings, not sites ;-)

--
Els http://locusmeus.com/
Sonhos vem. Sonhos vão. O resto é imperfeito.
- Renato Russo -


Reply With Quote
  #6  
Old   
Barbara de Zoete
 
Posts: n/a

Default Re: Style Sheet Question - 08-10-2005 , 04:21 AM



On Wed, 10 Aug 2005 10:14:00 +0200, Els <els.aNOSPAM (AT) tiscali (DOT) nl> wrote:

Quote:
Barbara de Zoete wrote:

On Wed, 10 Aug 2005 09:43:22 +0200, 'sNiek <n.emmen (AT) sebastian (DOT) nl> wrote:

I never use stylsheets in my HTML-mailings. Instead, I use plain
old-fashioned
HTML (font-tags and such).

So, I wonder: what is the best solution inline CSS or HTML?

Neither. HTML you should use for markup only. Analyse the content you're about
to offer and mark it up with some meaning to it. A heading is a heading, a
paragraph is a paragraph, a list is a list and so on. Once you've done that,
style your pages with CSS using a (external) stylesheet.

Barbara, Niek is talking about mailings, not sites ;-)

Ah, with his use of html message I couldn't read the font very well, misread
that bid. In that case a stylesheet in the head of the template should be a good
option.

The very best option would be not to use html for any kind of e-mail of course,
but that is probably only achievable in that perfect world I live in.

--
,-- --<--@ -- PretLetters: 'woest wyf', met vele interesses: ----------.
Quote:
weblog | http://home.wanadoo.nl/b.de.zoete/_private/weblog.html |
webontwerp | http://home.wanadoo.nl/b.de.zoete/html/webontwerp.html |
zweefvliegen | http://home.wanadoo.nl/b.de.zoete/html/vliegen.html |
`-------------------------------------------------- --<--@ ------------'



Reply With Quote
  #7  
Old   
Spartanicus
 
Posts: n/a

Default Re: Style Sheet Question - 08-10-2005 , 04:21 AM



"'sNiek" <n.emmen (AT) sebastian (DOT) nl> wrote:

Quote:
BTW: This is my first post in this newsgroup.
Some rules:

1) Configure your software to place an attribute line on top of follow
up messages.
2) Post only in plain text, HTML or mixed format is not welcome here.

--
Spartanicus


Reply With Quote
  #8  
Old   
Els
 
Posts: n/a

Default Re: Style Sheet Question - 08-10-2005 , 04:24 AM



Barbara de Zoete wrote:

Quote:
On Wed, 10 Aug 2005 10:14:00 +0200, Els <els.aNOSPAM (AT) tiscali (DOT) nl> wrote:

Barbara de Zoete wrote:

On Wed, 10 Aug 2005 09:43:22 +0200, 'sNiek <n.emmen (AT) sebastian (DOT) nl> wrote:

I never use stylsheets in my HTML-mailings. Instead, I use plain
old-fashioned
HTML (font-tags and such).

So, I wonder: what is the best solution inline CSS or HTML?

Neither. HTML you should use for markup only. Analyse the content you're about
to offer and mark it up with some meaning to it. A heading is a heading, a
paragraph is a paragraph, a list is a list and so on. Once you've done that,
style your pages with CSS using a (external) stylesheet.

Barbara, Niek is talking about mailings, not sites ;-)

Ah, with his use of html message I couldn't read the font very well,
Get Dialog. I see HTML messages in plain text - didn't even notice he
used HTML :-)

Quote:
misread that bid. In that case a stylesheet in the head of the
template should be a good option.
If that would work, but CSS styles in HTML mail aren't as reliable as
you would expect. I've tried it once, and some very basic styles just
didn't work.

Quote:
The very best option would be not to use html for any kind of e-mail of course,
Yup, agreed :-)

Quote:
but that is probably only achievable in that perfect world I live in.
If you see HTML postings as HTML postings, your world is less perfect
than mine! :P

--
Els http://locusmeus.com/
Sonhos vem. Sonhos vão. O resto é imperfeito.
- Renato Russo -


Reply With Quote
  #9  
Old   
Barbara de Zoete
 
Posts: n/a

Default Re: Style Sheet Question - 08-10-2005 , 04:42 AM



On Wed, 10 Aug 2005 10:24:16 +0200, Els <els.aNOSPAM (AT) tiscali (DOT) nl> wrote:

Quote:
Barbara de Zoete wrote:

[ styling mailings ]

Quote:
In that case a stylesheet in the head of the template should be a good option.

If that would work, but CSS styles in HTML mail aren't as reliable as
you would expect. I've tried it once, and some very basic styles just
didn't work.

Hmm, too bad :-D

Quote:
The very best option would be not to use html for any kind of e-mail of
course,

Yup, agreed :-)

but that is probably only achievable in that perfect world I live in.

If you see HTML postings as HTML postings, your world is less perfect
than mine! :P

Nope. Because I see html postings as html postings, I get the option to either
tell or killfile the poster. Either way, it reduces data traffic for me, and
with that for the internet as a whole. Thus I keep (re)creating my perfect
world, whereas yours has come to a stand still. Yours will get outdated some
time. Mine will be perfect for all the time future holds. :-D

--
,-- --<--@ -- PretLetters: 'woest wyf', met vele interesses: ----------.
Quote:
weblog | http://home.wanadoo.nl/b.de.zoete/_private/weblog.html |
webontwerp | http://home.wanadoo.nl/b.de.zoete/html/webontwerp.html |
zweefvliegen | http://home.wanadoo.nl/b.de.zoete/html/vliegen.html |
`-------------------------------------------------- --<--@ ------------'



Reply With Quote
  #10  
Old   
Alan J. Flavell
 
Posts: n/a

Default Re: Style Sheet Question - 08-10-2005 , 04:44 AM



On Wed, 10 Aug 2005, Barbara de Zoete wrote:

Quote:
On Wed, 10 Aug 2005 10:14:00 +0200, Els <els.aNOSPAM (AT) tiscali (DOT) nl> wrote:

Barbara, Niek is talking about mailings, not sites ;-)
[...]
The very best option would be not to use html for any kind of e-mail
of course, but that is probably only achievable in that perfect
world I live in.
Quite a few of us know that HTML-formatted emails are used by
mischievous/ malicious senders in unpleasant ways, and we have
configured our mail software to never automatically render
HTML-formatted mails.

I'd recommend anyone producing such mails to take that into account.
(I've seen situations where the sender has sent multipart/alternative
attachments in which the plain text alternative was empty: so be it,
we've viewed the empty attachment and discarded the email, moved on to
the next email, and never seen whatever it was that the sender wanted
to tell us!).

So: my mail reader, like that of many of my colleagues, is configured
to display only plain-text emails by default. If and when we choose
to read HTML-formatted content, it's only after carefully inspecting
the origin of the mail, to be convinced that it's bona fide, and then
taking additional action to tell the mail reader to view the HTML
format.

It's actually much more effective (if a formatted document is really
needed, which in most cases isn't so - but let's suppose for the sake
of discussion that it is) if the sender will send us a plain text mail
containing the substantive content (or a summary of it), together with
a URL of a web page where we can view the intended formatted article
via http. The security aspects of viewing a remote web page seem to
us to be much better controlled than trying to use a mail reader to
view a local copy of a formatted HTML attachment that has arrived from
a potentially untrusted source. Recall that the apparent sender
address of an email is readily faked, so it needs more than just
inspection of the apparent sender address to be sure that the mail is
genuine.

I don't for a moment accuse this particular sender of mischief, but
I'm afraid the mail reader options have to be set to deal with all
possibilities, and we prefer to err on the side of safety. Speaking
specifically about Windows-based users, we've got one user who
disregards this kind of advice, and he seems to acquire a new virus
infection at least once a week, sometimes more frequently, by his
careless behaviour; whereas it's rare for *any* of the rest of our
Windows-based users to be afflicted by viruses from one year to
another.


Reply With Quote
Reply




Thread Tools
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

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Powered by vBulletin Version 3.5.4
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.