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 gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Style Sheet question (css)

Status
Not open for further replies.

daph

Programmer
Jun 9, 2000
65
CA
Hey everyone!<br><br>I know this isn't javascript related, but I didn't know where else to ask my question...I'm working with cascading style sheets right now, and I was wondering if anyone ever worked with these &quot;classes&quot; in it...I want to use some specific styles, but not to a particular tag...I would like to be able to use it with anything. (ex: with &lt;p&gt;, &lt;div&gt;, etc) I've tried it like this:<br><br>[in style sheet]&nbsp;&nbsp;&nbsp;&nbsp;.text {font-weight:bold;<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;font-color:#000040 }<br><br>[in html doc]&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&lt;p class=&quot;.text&quot;&gt;...blabla &lt;/p&gt;<br><br>This is suppose to work, but I don't have the results I want...anybody know anything about this type of class or any other way I could do this? Thank you soooo much! :)<br><br>daph
 
when decalring style sheet classes, you use the dot before the name:<br><br>.bigfreakingredtext {...}<br><br>You use it in your HTML like so:<br>&nbsp;<br>&lt;p class=&quot;bigfreakingredtext&quot;&gt;<br><br>Notice there is no dot in the HTML version.<br><br><A HREF="mailto:jared@aauser.com">jared@aauser.com</A>
 
Thank you :)<br><br>Would you know if there are any options in FrontPage that would show the changes for these classes? It works when I visualize it on the web, but in FrontPage, with Preview, it doesn't change anything...<br><br>Thanks again...<br><br>daph
 
Most likely you are using some sort of script to process or open the stylesheet.&nbsp;&nbsp;That script or asp file won't get processed through frontpage.
 
Why don't you just try coding without a generator instead.
 
I'm working with FrontPage because I'm doing this for an organization and they work with the software...for my personal pages, I usually just use the simplest thing :)
 
daph - <br><br>just so you know, in css, there are also id's<br><br>they exactly the same, with only one difference:<br><br>instead of a dot, use a pound (#) sign<br><br>ex:<br><i>&lt;style&gt;<br>#myId {...}<br>&lt;/style&gt;<br>&lt;div id=myId&gt;junk in div&lt;/div&gt;<br></i><br><br>just so you know. <p>theEclipse<br><a href=mailto:eclipse_web@hotmail.com>eclipse_web@hotmail.com</a><br><a href=robacarp.webjump.com>robacarp.webjump.com</a><br>**-Trying to build a documentation of a Javascript DOM, crossbrowser, of course. E-mail me if you know of any little known events and/or methods, etc.
 
I don't know about you... but I find Notepad a LOT simpler than Frontpage :eek:) <p>Liam Morley<br><a href=mailto:lmorley@wpi.edu>lmorley@wpi.edu</a><br><a href=] :: imotic :: website :: [</a><br>"light the deep, and bring silence to the world.<br>
light the world, and bring depth to the silence.
 
I would have to agree...once for a class we were assigned to make webpages, and everyone was using Netscape Composer, and it confused the hell out of me. = )<br><br>I need to get Allaire HomeSite 4.5, I heard its really good for coding HTML.
 
Well if I had to use a WYSIWYG editor, I'd probably go with Dreamweaver... but I use Notepad exclusively. I've heard Allaire has a good product, and it doesn't hurt to have the name to go with ColdFusion... <p>Liam Morley<br><a href=mailto:lmorley@wpi.edu>lmorley@wpi.edu</a><br><a href=] :: imotic :: website :: [</a><br>"light the deep, and bring silence to the world.<br>
light the world, and bring depth to the silence.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top