Solved

CSS not working for one class (documents attached)

Posted on 2012-12-23
5
466 Views
Last Modified: 2012-12-26
My webpage does not respond to a class named .topic in my CSS. I'm applying .topic to four <td> tags in my webpage. Here is the formatting in .topic.

.topic {font-variant: small-caps;
        text-align: center;}        

This doesn't work. But if I embed .topic in the head of my webpage as shown below, the formatting works.

<style type="text/css">
.topic {font-variant: small-caps;
        text-align: center;}        
</style>

 If you copy the .topic formatiing from the CSS and paste it between <style type="text/css"> and </style>,  you'll see what I'm talking about. Why does .topic work as an embedded style but not from an external style sheet?
stylesheet.css
aSurgery.htm
0
Comment
Question by:MBarongan
  • 3
  • 2
5 Comments
 
LVL 29

Expert Comment

by:IrogSinta
ID: 38717918
Your stylesheet is missing a closing curly bracket for your category class.
.category {font-family: arial;
         font-size: 2em;
         text-align: center;
         line-height: 2.25em; }
0
 

Author Comment

by:MBarongan
ID: 38718301
Yes, that was the problem. I was too busy focusing on .topic that i didn't notice that .category above .topic was missing a bracket. Thank you.
0
 

Author Comment

by:MBarongan
ID: 38721589
I've requested that this question be closed as follows:

Accepted answer: 0 points for MBarongan's comment #a38718301

for the following reason:

Issue is resolved.
0
 
LVL 29

Accepted Solution

by:
IrogSinta earned 500 total points
ID: 38718688
Did my answer not help you out?
0
 

Author Closing Comment

by:MBarongan
ID: 38721590
Your answer was perfect. I just didn't close the question properly. Sorry for the confusion. And thanks for your help.
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

So you have coded your own WordPress plugin and now you want to allow users to upload images to a folder in the plugin folder rather than the default media location? Follow along and this article will show you how to do just that!
Use these top 10 tips to master the art of email signature design. Create an email signature design that will easily wow recipients, promote your brand and highlight your professionalism.
In this tutorial viewers will learn how to code links for mobile sites that, once clicked, send a call or text to a specified number. For a telephone link (once clicked, calls a number), begin with a normal "<a href=" link tag. For the href, specify…
In this tutorial viewers will learn how to style a decorative dropcap for the first letter in a paragraph using CSS. In CSS, create a new paragraph class by typing "p.fancy": Then, to style only the first letter of the first sentence, include the ps…

895 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

11 Experts available now in Live!

Get 1:1 Help Now