PDA

View Full Version : Default font


00XxXxX00
03-29-2003, 10:14 PM
Ok, default fonts lookall different on other computers, so how could I made this code, have a default font of verdana point size 2. I want the java at the top, that pops up to have verdana point size two.

<script>
var changelayer;
function change_message(message){
if(document.layers){ // for NN4
changelayer = document.layers["description"];
changelayer.document.open();
changelayer.document.write(message);
changelayer.document.close();
}
if(document.all){ // for IE
changelayer = document.all["description"];
changelayer.innerHTML=message;
}
if(!document.all && document.getElementById){ // for NN6
changelayer = document.getElementById("description");
changelayer.innerHTML=message;
}
}


</script>

<html>
<head>
<style type="text/css"><!--
a {text-decoration:none;}
a:link {color:ffffff;}
a:visited {color:ffffff;}
a:active {color:ffffff;}
a:hover{color:0099cc;
text-decoration:underline overline;
background-color:000000;}
--></style>
<title></title>
<style>
#description {
color: #FFFFFF;
}
</style>
<style type="text/css"><!--
a {text-decoration:none;}
a:link {color:ffffff;}
a:visited {color:ffffff;}
a:active {color:ffffff;}
a:hover{color:0099cc;
text-decoration:underline overline;
background-color:000000;}
--></style>
</head>
<body bgcolor="#000000">
<div id="description"><font color="#FFFFFF"><font face="Verdana" size="2" color="#FFFFFF">Go Skateboard</font></div><div align="left"><table border="1" cellpadding="0" cellspacing="0" style="border-collapse: collapse" bordercolor="#111111" width="190" height="1"> <tr> <td width="222" height="1" bgcolor="#111111" bordercolor="#333399"> <p align="left"><font color="#FFFFFF" face="CheckFontMedExt"><center><img src="image2.gif" width="170" height="32"></center></font></td> </tr> </table></div><div align="left"> <table border="1" cellpadding="0" cellspacing="0" style="border-collapse: collapse" bordercolor="#006699" width="190" height="206" bgcolor="#111111"> <tr> <td width="190" height="206">
<p align="center"> <font face="Verdana" size="2" color="#FFFFFF"><center><a href="http://www.geocities.com/riwskate/ourpics" onmouseout="change_message(' ')" onmouseover="change_message('See The Team in Action')">«Skate Photos»</a><br>
<a href="http://www.geocities.com/riwskate/rifootage" onmouseover="change_message('See Our Latest Moves on Film')" onmouseout="change_message('Go Skateboard')">«Skate Footage»<br></a>
<a href="http://www.geocities.com/riwskate/tricktips" onmouseover="change_message('Learn Tricks from us')" onmouseout="change_message('Go Skateboard ')">«Skate
Trick tips»<br></a><a href="http://www.geocities.com/riwskate/skatespots" onmouseover="change_message('Rhode Islands best Locations')" onmouseout="change_message(' Go Skateboard')">«Spot Check»<br></a><a href="http://www.geocities.com/riwskate/ourprofiles" onmouseover="change_message('Get to know the Team')" onmouseout="change_message(' Go Skateboard')">«RI Profiles»<br></a><a href="http://www.geocities.com/riwskate/latestnews" onmouseover="change_message('Latest news in the Skate World')" onmouseout="change_message('Go Skateboard ')">«Latest News»<br></a><a href="http://www.geocities.com/riwskate/skaterisland" onmouseover="change_message('See RIs local Skatepark')" onmouseout="change_message('Go Skateboard ')">«Skater Island Footage»</a>
<a href="http://www.geocities.com/riwskate/rifootage" onmouseover="change_message('See Our Latest Moves on Film')" onmouseout="change_message('Go Skateboard')"><br></a>
<a href="http://www.geocities.com/riwskate/prophotos" onmouseover="change_message('See the best Pros Tear it Up')" onmouseout="change_message('Go Skateboard ')">«Professional Footage»</a>
<a href="http://www.geocities.com/riwskate/protips" onmouseover="change_message('Learn from the Pros')" onmouseout="change_message('Go Skateboard ')">«Professional
Trick tips»</a><br>
<a href="http://www.geocities.com/riwskate/skatelogos" onmouseover="change_message('Some cool Graphics')" onmouseout="change_message('Go Skateboard ')">«Skateboarding Logos»</a><br>
<a href="http://www.geocities.com/riwskate/rampplans" onmouseover="change_message('Want your own ramp? Learn')" onmouseout="change_message('Go Skateboard ')">«Ramp Plans»</a><br>
<a href="http://www.geocities.com/riwskate/latestevents" onmouseover="change_message('This Months Outlook')" onmouseout="change_message(' Go Skateboard')">«Coming Events»</a><br>
<a href="http://skateri.proboards14.com/index.cgi" onmouseover="change_message('Interact with other Skaters')" onmouseout="change_message(' Go Skateboard')">«Message Boards»</a><br>
<a href="http://www.geocities.com/riwskate/skat" onmouseover="change_message('Chatroom')" onmouseout="change_message(' ')">«Skate Lounge»</a><br></center></font>
<center><a href="http://www.geocities.com/riwskate/submitform" onmouseover="change_message('Want to share something?')" onmouseout="change_message('Go Skateboard ')"><font face="Verdana"><font size="2">«Submit
Info»</font></font></a><font size="3"><br></font>
<a href="http://www.geocities.com/riwskate/love" onmouseover="change_message('RI Skate short movies')" onmouseout="change_message('Go Skateboard')"><basefont face="verdana" size="2">«For the Love»</a><br>
<a href="http://www.geocities.com/rookiesskate/" onmouseover="change_message('RI Skateboarding Movie')" onmouseout="change_message('Go Skateboard')"><basefont face="verdana" size="2">«Rookies»</a>
</center>
</td></tr> </table></div><div align="left">
</div>

COBOLdinosaur
03-30-2003, 12:18 AM
#description {font-family:verdana;font-size:2pt}


But the user can override it locally anyway.

cg9com
03-30-2003, 02:49 AM
as cobol stated, your user can overide your CSS with whats called a user stylesheet.
in IE6: Tools > Internet Options > Accessibility

also, if your specifying more than one attribute for a font, you can use shorthand, no difference from the above solution, just shorter (hence the name duh? :D)

font:2pt verdana;

but try not to use point sizes, its up to you but in IE the user cannot resize the text, so with 2 it would be pretty small, and if the user cant read it they are out of luck. you can try a different measurement if you want, such as em or percentages, both are explained how they are used by Catman and beetle in this thread:
http://www.codingforums.com/showthread.php?s=&threadid=13420

meow
03-30-2003, 04:37 AM
2pt? That's about the size of this ---> ,
:D

00XxXxX00
03-31-2003, 02:29 AM
Now where do I put that? font size code?

cg9com
03-31-2003, 03:15 AM
:)
The CSS? Would go in your style element, <style></style>.