Forums / Templates, Stylesheets, Page Layout / CSS drop shadow text

CSS drop shadow text

Locked

Started by studeo on 27 Jan 2007, 8:20 PM · Views: 4,981

Results 1 to 15 of 15
This thread is locked. New replies are disabled.
27 Jan 2007, 8:20 PM
#1
studeo avatar

studeo

Zen Follower

Join Date:
Jan 2007
Posts:
198
Plugin Contributions:
0

CSS drop shadow text

I'm a bit new to css but I can find my way around. I am trying to add a drop shadow to the text defined as H1 in the default stylesheet. I have searched the web only to be confused as to what code is needed and where it goes. If you have had some experience adding this element would you please post some details on its implementation and its coding?

Very grateful for an answer.

Thank You.

28 Jan 2007, 12:09 AM
#2
studeo avatar

studeo

Zen Follower

Join Date:
Jan 2007
Posts:
198
Plugin Contributions:
0

Re: CSS drop shadow text

I see that I now have to change the product description from h1 to a new tag. I made h7 but I cant seem to implement it from the products_info_display page unless I didnt change what I should have. Any ideas?

28 Jan 2007, 12:18 AM
#3
jettrue avatar

jettrue

Totally Zenned

Join Date:
Jan 2005
Location:
USA, St. Louis
Posts:
3,651
Plugin Contributions:
5

Re: CSS drop shadow text

Err, that's not really a css standard right now? I would call that an advanced, advanced, if you wanna get really fancy and technical thing, its not a use on a regular ole website thing yet. I had never really heard of it, and doing a google on the matter showed some complicated javascript and css hacking that is just a big undertaking.

Do you want to do this for a logo or something? This would be something better done manually with an image program vs. trying to hack it, imo, and would probabl look better as well.

28 Jan 2007, 12:27 AM
#4
studeo avatar

studeo

Zen Follower

Join Date:
Jan 2007
Posts:
198
Plugin Contributions:
0

Re: CSS drop shadow text

OK I'm including some code to try and call h7 to the product name line which is not working:

<!--bof Product Name-->
<h7 id="productName" class="productGeneral"><?php echo $products_name; ?></h7>
<!--eof Product Name-->

but its stays small black lettering which I dont want...aaarrrggghhh!!!

28 Jan 2007, 2:28 AM
#6
jettrue avatar

jettrue

Totally Zenned

Join Date:
Jan 2005
Location:
USA, St. Louis
Posts:
3,651
Plugin Contributions:
5

Re: CSS drop shadow text

studeo:

OK I'm including some code to try and call h7 to the product name line which is not working:

<!--bof Product Name-->

<h7 id="productName" class="productGeneral"><?php echo $products_name; ?></h7>

<!--eof Product Name-->
> 
> but its stays small black lettering which I dont want...aaarrrggghhh!!!

Cause css text drop shadows is not something that is reasonable to try and do... sorry! Its just really not supported by browsers.
28 Jan 2007, 2:54 AM
#7
studeo avatar

studeo

Zen Follower

Join Date:
Jan 2007
Posts:
198
Plugin Contributions:
0

Re: CSS drop shadow text

ok I give up on the drop shadows...but I want to be able to control the product_name on the product page with its own style and not with h1 and I'm being dense...any suggestions?

28 Jan 2007, 2:55 AM
#8
Kim avatar

Kim

Obaa-san

Join Date:
Jun 2003
Location:
West Coast, North America
Posts:
26,732
Plugin Contributions:
0

Re: CSS drop shadow text

You can style the H1- make it any size any color any spacing you want- use the stylesheet

Please do not PM for support issues: a private solution doesn't benefit the community.

Be careful with unsolicited advice via email or PM - Make sure the person you are talking to is a reliable source.

28 Jan 2007, 2:58 AM
#9
studeo avatar

studeo

Zen Follower

Join Date:
Jan 2007
Posts:
198
Plugin Contributions:
0

Re: CSS drop shadow text

I know...i think I need to create a new style (i created h7 based on h1) but cannot glue it to the product display page product name.

28 Jan 2007, 2:59 AM
#10
jettrue avatar

jettrue

Totally Zenned

Join Date:
Jan 2005
Location:
USA, St. Louis
Posts:
3,651
Plugin Contributions:
5

Re: CSS drop shadow text

studeo:

ok I give up on the drop shadows...but I want to be able to control the product_name on the product page with its own style and not with h1 and I'm being dense...any suggestions?

If you want to change it from H1, cause you want it to be different than OTHER h1, sure, you can change it to h7.

Then in your stylesheet, style h7 the way you want it, kind of like this:

h7 {

font-size:1.4em;
color:#000000;
font-weight:bold;

}

28 Jan 2007, 3:23 AM
#12
studeo avatar

studeo

Zen Follower

Join Date:
Jan 2007
Posts:
198
Plugin Contributions:
0

Re: CSS drop shadow text

I created:

h7 { 
font-size: 12px; 
color: #990000;
padding: 2px 0px; 
margin: 0.1em 0 0em;
font-weight: bold; 
font-family: Geneva, Arial, Helvetica, san-serif; 
font-style: italic; 
background-color: #FFFFFF}

 }

and changed the tag in tpl_product_info_display.php to:

<!--bof Product Name-->
<h7 id="productName" class="productGeneral"><?php echo $products_name; ?></h7>
<!--eof Product Name-->

with no result. I must be missing something.

You see, I put an image background on the original h1....but it also displayed on the product name line. And ratherd badly.

heres a link:

theribbondiva

and thanks for your replies

28 Jan 2007, 3:45 AM
#13
jettrue avatar

jettrue

Totally Zenned

Join Date:
Jan 2005
Location:
USA, St. Louis
Posts:
3,651
Plugin Contributions:
5

Re: CSS drop shadow text

studeo:

I created:

h7 {
font-size: 12px;
color: #990000;
padding: 2px 0px;
margin: 0.1em 0 0em;
font-weight: bold;
font-family: Geneva, Arial, Helvetica, san-serif;
font-style: italic;
background-color: #FFFFFF}

}

> 
> and changed the tag in tpl_product_info_display.php to:
> 
> ```
<!--bof Product Name-->
<h7 id="productName" class="productGeneral"><?php echo $products_name; ?></h7>
<!--eof Product Name-->

with no result. I must be missing something.

You see, I put an image background on the original h1....but it also displayed on the product name line. And ratherd badly.

heres a link:

theribbondiva

and thanks for your replies

It's still showing up as an h1, so perhaps you didn't make the change in your custom folder?

Anyway, instead, style the product name with this tag in the stylesheet:

h1#productName {}

28 Jan 2007, 3:59 AM
#14
studeo avatar

studeo

Zen Follower

Join Date:
Jan 2007
Posts:
198
Plugin Contributions:
0

Re: CSS drop shadow text

I want to thank you very much. I ditched the h7 tag and added the #productName to the stylesheet as you suggested above. Then I styled the #productName tag as I wanted and all is well at the moment. I can't thank you enough!

28 Jan 2007, 9:47 AM
#15
still_crazy avatar

still_crazy

New Zenner

Join Date:
Sep 2006
Location:
Derby UK
Posts:
97
Plugin Contributions:
0

Re: CSS drop shadow text

I would use an image if I were you as there are a couple of problems I can think of with doing it in CSS.

Firstly - Accessibility: People using text browsers will see the description twice, which can be annoying. Likewise anyone using an Aural browser will hear the words spoken twice, again annoying.

Secondly, and probably most importantly for most people [at the moment anyway] - the search engines will at least down grade your site [and possibly ban it] if they think that you are keyword spamming - and the product description is an important keyword.

Just my opinion.

Crazy