Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

CSS - ouline text

Status
Not open for further replies.
May 13, 2005
56
US
Is there a way with CSS to outline text on a page?

I have some large text that is blue on one of my pages and I want to outline the text with a black 1px border..

Thanks,

Mike
 
um...
Code:
<span style="font-size:18pt; color:#00f; border:1px solid #000;">this is my big blue outlined text</span>


-jeff
try { succeed(); } catch(E) { tryAgain(); } finally { rtfm(); }
i like your sleeves...they're real big
 
Thank you, I didnt think of trying it like that, I am still learning CSS and I was not using the <span> tags.. I'll try that out..

I just have some Text inside a <div> that I had all the properties set for except a border on the text..
 
I'm sorry, just tried that out.. That is not what I was looking for..

What I am looking for is something like this

this is an image that I created with photoshop. The bottom word has a black outline around it using the stroke command in photoshop..

Any way to simulate the bottom text with CSS styles?

Thanks again,

Mike
 
that is not possible with css. about the closest i've seen is simulating a drop shadow by using two containers with the same text, one positioned behind the first and slightly offset

-jeff
try { succeed(); } catch(E) { tryAgain(); } finally { rtfm(); }
i like your sleeves...they're real big
 
You could explore the filters listed in faq215-3207 . They only work in Internet Explorer, but produce the kind of effect you're after. Provided the text can still be read in other browsers, this might suit you.

Otherwise you'll have to either use images (don't forget the alt attribute) or maybe Flash (take a look at for a text-replacement technique)

-- Chris Hunt
Webmaster & Tragedian
Extra Connections Ltd
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top