Suzanne;
Since none of the text chunks would seem to fit a particular semantic
markup tag, I would suggest wrapping each 'chunk' apart from the first
one in a <span> with a suitable class, eg:
<p>Name: John Doe<span class="spacedOut">020 7000 0000</span><span
class="spacedOut">[EMAIL PROTECTED]</span></p>
then apply padding to the left of those spans. Eg:
.spacedOut {
padding-left: 2em;
}
The text itself takes its style (font, colour etc) from whatever is set
up for the <p> tag, so no need to specify that again, just do the
padding to push the spans apart a bit.
Of course, if you want each text chunk to be styled differently, just
give the spans unique classes -- eg. "phone", "email" etc.
Some may not like the non-semantic spans... but it's an easy way to
accomplish what you're after. Anyone have a more semantic way of doing
it? I'd love to know it.
Rick
--
**ORIGINAL MESSAGE**
Received from [EMAIL PROTECTED]
on 20/6/07 at 16:00(London time):
>
>Hi everyone,
>
>I was wondering if anyone has a link or information as how to best handle
>text with CSS. By text I mean a line of text that may include 3 pieces of
>information, like name, phone, and email address.
>
>In the past, I always used tables for this, but want to handle this with
>the use of CSS if possible.
>
>I found a site that mentioned word-spacing, but that won't work because I
>don't want a large amount of spacing between the first and last name.
>
>Any suggestions or links are greatly appreciated.
>
>Thanks! ;-)
>
>Suzanne
______________________________________________________________________
css-discuss [EMAIL PROTECTED]
http://www.css-discuss.org/mailman/listinfo/css-d
IE7 information -- http://css-discuss.incutio.com/?page=IE7
List wiki/FAQ -- http://css-discuss.incutio.com/
Supported by evolt.org -- http://www.evolt.org/help_support_evolt/