PDA

View Full Version : I need HELP with those shadow text thingys!



carlito
December 12th, 2003, 22:32
Does any remember occaisonaly you come across that text with a shadow behind it? Or rather it is embossed or blurred?

What is the HTML code to do that? I can't find an example of it anywhere, but maybe you guys remember how?

thankx

Loon
December 13th, 2003, 10:09
css2 has a text-shadow property but i think the only browser supporting it so far is safari :mad:

You could use filters to create a shadow that would work in IE, other browsers would have problems but at least that's most of your traffic.

something like:



<style type="text/css">
body div {
width : 300px;
height : 20px;
font-size : 20pt;
font-weight : bold;
font-family : verdana, tahoma, arial;
filter: DropShadow(Color=#DDDDDD, OffX=2, OffY=2, Positive=true);
}
</style>
<div>This Is My Text</div>

To get somethng that's more browser universal, you could do it with some fancy positioning, and have the text twice, one slightly offset against the other.

carlito
December 14th, 2003, 05:01
Originally posted by Loon
To get somethng that's more browser universal, you could do it with some fancy positioning, and have the text twice, one slightly offset against the other. [/B]

thanks for ur help :)

do u know the HTML for that ?

ConfusedSoul20C
December 23rd, 2003, 10:41
It most likely wouldn't be html, but CSS (or CSS2) or quite possibly php.

Loon
December 23rd, 2003, 18:26
well i had a quick stab at it, you'd have to really just play around alot.

This way would be fine if you just wanted to do it say for a title, but for lots of text it would be a nightmare, to get all the positioning right.


<style type="text/css">
#top {
color : #DDDDDD;
font-size : 20pt;
font-family : tahoma, verdana, arial;
}
#shadow {
left : +0.08em;
top : -1.10em;
position: relative;
color : #616161;
font-size : 20pt;
font-family : tahoma, verdana, arial;
}
</style>
<div id="top">this is my text</div>
<div id="shadow">this is my text</div>

Here's the result (http://netcode.net/shadow.html)

Arrgh, i named them back to front lol, tired :confused2 (still works though)

Wojtek
December 23rd, 2003, 20:02
why not just photoshop what you need?