This is Interesting: Free Magazines for Graphics designers and webmasters  


Home > Archive > Dreamweaver > September 2005 > css question





You are viewing an archived Text-only version of the thread. To view this thread in it's original format and/or if you want to reply to this thread please [click here]

Author css question
David Burley

2005-09-29, 6:17 pm

I have a bit of text that I would like to underline but I want the underline
to go past the text so I tried the following in my style sheet:

border-bottom-width: thin;
border-bottom-style: solid;
border-bottom-color: 322775;

This is ok, but it spans the area it is in, I'd actually like it to go
somewhere inbetween the end of the text and the right margin.

Thanks...and if this is not a good forum for this, could someone point me to
one that is.


W.Schneider

2005-09-29, 6:17 pm

Hi David

you should use a class:

<Copy&Paste this>

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
"http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<title>Underline Class</title>
<style type="text/css">
<!--
..underline {
width: 200px;
border-bottom-width: 1px;
border-bottom-style: solid;
border-bottom-color: #FF6633;
}
-->
</style>
</head>

<body>
<p class="underline">Underline
</p>
</body>
</html>

</End Copy&Paste>

Greetings

Willi

"David Burley" <dburley@hannaford.com> schrieb im Newsbeitrag
news:dhgspg$e0j$1@forums.macromedia.com...
>I have a bit of text that I would like to underline but I want the
>underline
> to go past the text so I tried the following in my style sheet:
>
> border-bottom-width: thin;
> border-bottom-style: solid;
> border-bottom-color: 322775;
>
> This is ok, but it spans the area it is in, I'd actually like it to go
> somewhere inbetween the end of the text and the right margin.
>
> Thanks...and if this is not a good forum for this, could someone point me
> to
> one that is.
>
>



Al Sparber- PVII

2005-09-29, 6:17 pm

CSS borders are based upon the width of the element you are assigning
the border to. If the text is inline, it's difficult, though possible -
though your description leaves a lot to guesswork. Where is the text and
what is its nature? What kind of element is the text in?



--
Al Sparber - PVII
http://www.projectseven.com
DW Extensions - Menu Systems - Tutorials - CSS FastPacks
---------------------------------------------------------
Webdev Newsgroup: news://forums.projectseven.com/pviiwebdev/
CSS Newsgroup: news://forums.projectseven.com/css/
RSS/XML Feeds: http://www.projectseven.com/xml/




"David Burley" <dburley@hannaford.com> wrote in message
news:dhgspg$e0j$1@forums.macromedia.com...
>I have a bit of text that I would like to underline but I want the
>underline
> to go past the text so I tried the following in my style sheet:
>
> border-bottom-width: thin;
> border-bottom-style: solid;
> border-bottom-color: 322775;
>
> This is ok, but it spans the area it is in, I'd actually like it to go
> somewhere inbetween the end of the text and the right margin.
>
> Thanks...and if this is not a good forum for this, could someone point
> me to
> one that is.
>
>


David Burley

2005-09-29, 6:17 pm

nevermind,

I added this...

width: 80%;


"David Burley" <dburley@hannaford.com> wrote in message
news:dhgspg$e0j$1@forums.macromedia.com...
> I have a bit of text that I would like to underline but I want the

underline
> to go past the text so I tried the following in my style sheet:
>
> border-bottom-width: thin;
> border-bottom-style: solid;
> border-bottom-color: 322775;
>
> This is ok, but it spans the area it is in, I'd actually like it to go
> somewhere inbetween the end of the text and the right margin.
>
> Thanks...and if this is not a good forum for this, could someone point me

to
> one that is.
>
>



W.Schneider

2005-09-29, 6:17 pm

Hi David,

my favorite forums for css related topics is "forums.projectseven.com".
See Al's Post a minute ago.

Greetings Willi


"David Burley" <dburley@hannaford.com> schrieb im Newsbeitrag
news:dhgspg$e0j$1@forums.macromedia.com...
>I have a bit of text that I would like to underline but I want the
>underline
> to go past the text so I tried the following in my style sheet:
>
> border-bottom-width: thin;
> border-bottom-style: solid;
> border-bottom-color: 322775;
>
> This is ok, but it spans the area it is in, I'd actually like it to go
> somewhere inbetween the end of the text and the right margin.
>
> Thanks...and if this is not a good forum for this, could someone point me
> to
> one that is.
>
>



smanatt

2005-09-29, 6:17 pm

Just add a series of "&nbsp;" (Ctrll + Space in DW) after the text and use the Text-decoration:underline; style.
Michael Fesser

2005-09-29, 6:18 pm

..oO(David Burley)

>I have a bit of text that I would like to underline but I want the underline
>to go past the text so I tried the following in my style sheet:


Be aware that underlining text is usually not the best idea. It might
confuse users, because they would expect the underlined text to be a
link. If it's just for emphasis try to find another way, either using a
different color and/or bold text.

>border-bottom-width: thin;
>border-bottom-style: solid;
>border-bottom-color: 322775;


Can be reduced to

border-bottom: thin solid #322775;

(In your code the '#' is missing!)

Micha
Sponsored Links


Copyright 2003 - 2008 forum4designers.com  Software forum  Computer Hardware reviews