Forum Moderators: open

Message Too Old, No Replies

Text Effects

I am looking for text effects just as the italicized text. Plz reply. =)

         

HTMLwalker

9:27 pm on Aug 4, 2003 (gmt 0)

10+ Year Member



I am looking for text effects. You know when you use a word processor they give you choices like bold text? I am looking for the HTML Codes of text effects like that strikethrough text effect, which makes a line through the text. Please help me with this! ;-)

vincevincevince

9:41 pm on Aug 4, 2003 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



<b>Bold</b>
<em>Emphasis</em> -- intepretted by majority of browsers as italic

and see also the css equivalents of the form

<p style="font-X:Y"> </p>

(google for css font)

Sinner_G

9:47 pm on Aug 4, 2003 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



I also often see italic as <i></i>.

The line through text effect is achieved by <s></s>.

NickH

9:56 pm on Aug 4, 2003 (gmt 0)

10+ Year Member



If you're just looking for the physical appearance of strikethrough, you can use <strike> or <s>. I've heard the former is more widely supported in older browsers.

If you want to use logical markup to indicate document changes, there are the <ins> and <del> tags. The advantage of these tags is that they hold semantic meaning, and also support a timestamp attribute. On the other hand, I believe they're not as widely supported by older browsers as the physical tags, mentioned above.

Nick

photon

1:06 pm on Aug 5, 2003 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



I just wanted to note that the <b> tag has been deprecated. <strong> -- which is interpreted as bold by most browsers -- is recommended.

Ryan8720

1:42 pm on Aug 5, 2003 (gmt 0)

10+ Year Member



All of those will be deprecated soon in favor of CSS. To do those in CSS:

.effects {
text-decoration: underline;
text-decoration: line-through;
text-decoration: overline;
font-weight: bold;
font-style: italic;
}

Note: you can't have more that one text-decoration.

photon

2:51 pm on Aug 5, 2003 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Ryan8720--

Are you saying that the <em> and <strong> tags are being deprecated as well? I thought they were replacements for the <b> and <i> tags because they were semantically (instead of stylistically) relevant. Also, for that reason, I believe that they have meaning to screen readers as well, which CSS styles would not.

insin

3:32 pm on Aug 5, 2003 (gmt 0)

10+ Year Member




Note: you can't have more that one text-decoration.

You can add the different decorations you want into one text-decoration declaration as a list:


.thisClass {
text-decoration: underline overline line-through;
}