|
-
May 28th, 2002, 07:18 AM
#1
Thread Starter
Frenzied Member
Simple question concerning CSS and HTML
How do I set apply a class on an entire table?
Code:
<table>
<tr>
<td>This is the test</td>
<td>A new line</td>
</tr>
</table>
-
May 28th, 2002, 07:21 AM
#2
PowerPoster
Not quite sure what u mean but anyhow u really arent supposed to use 'tables' in CSS. U should use <div> tags. Do u know anything about CSS already? What do u want to do and what do u already know how to do.
-
May 28th, 2002, 07:48 AM
#3
Thread Starter
Frenzied Member
Sorry for beeing unprecise, I only want to know how I can define my font size of all the fields in a table
-
May 28th, 2002, 07:55 AM
#4
Fanatic Member
<style type="text/css">
td,th,body { font-size: 10px; font-family: Verdana;}
</style>
-
May 28th, 2002, 07:55 AM
#5
Fanatic Member
<table class="classname"> should work.
<table style="font-family:arial; font-size:8pt;">
-
May 28th, 2002, 08:00 AM
#6
PowerPoster
Sorry for not answering directly but I think that u are attempting to jump into something in CSS without knowing enough of the basics. U need to create a separate css file with #frame properties and paragraph properties and then use them to build your "tables".
here's a sample CSS file and html file
VB Code:
'Called yourstyles.css
body {
text-align: center;
background: url(back.gif) fixed;
margin-left: 0;
margin-top: 0;
}
A {
color: #000080;
text-decoration:none
}
A:hover {
color: #FF0000;
font-family: Verdana, Helv, Arial;
}
A:visited {
color: #000080;
font-family: Verdana, Helv, Arial;
}
#frame {
width:750px;
margin-right: auto;
margin-left:auto;
margin-top:20px;
padding:0px;
background:#fff;
text-align:center;
border:4px solid #000;
}
#frameinner {
width:742px;
margin-right: auto;
margin-left:auto;
padding:0px;
background:#fff;
text-align:left;
}
#contentheader {
text-align: left;
padding: 7px;
background:#fff;
}
#contentleft {
width:340px;
padding: 0px;
float:left;
text-align:center;
background:#fff;
}
#contentright {
width: 340px;
padding: 0px;
float:left;
text-align:left;
background:#fff;
}
#contentfooter {
text-align: left;
padding: 7px;
background:#fff;
}
p.standard {
margin-left: 0;
margin-top: 10px;
align:left;
font-family: Verdana, Helv, Arial;
font-size: 12px;
font-color: #000;
}
p.footer {
margin-left: 333px;
margin-top: 10px;
align:left;
font-family: Verdana, Helv, Arial;
font-size: xx-small;
font-color: #000;
}
VB Code:
<html>
<head>
[b]<link rel=stylesheet href="yourstyles.css" type="text/css">[/b]
</head>
<body>
<div id="frame">
<div id="contentheader">
'Something in here
</div>
<div id="frameinner">
<div id="contentleft">
<img src="somepic.gif"><br>
<br><br>
</div>
<div id="contentright">
<img src="someotherpic.gif"><br>
<p class="standard">
Some text<br>
</p>
</div>
</div>
</div>
</body>
</html>
Hopefully this gives u some ideas
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|