We hope you enjoy your visit.

You're currently viewing our forum as a guest. This means you are limited to certain areas of the board and there are some features you can't use. If you join our community, you'll be able to access member-only sections, and use many member-only features such as customizing your profile, sending personal messages, and voting in polls. Registration is simple, fast, and completely free.


Join our community!


If you're already a member please log in to your account to access all of our features:

Username:   Password:
Add Reply
  • Pages:
  • 1
  • 3
Add more Fonts
Topic Started: May 7 2010, 11:59 PM (7,796 Views)
Agent Moose-ZNR
Member Avatar
♪ === ♥
[ *  * ]
I was looking around and I realized (after searching) that there wasn't a "Add more Fonts" code, so I decided to make that simple code. ^_^

Below the Board:
Code:
 
<script type="text/javascript">
var FontFace = new Array(), w = 0;
FontFace[w++] = "Arial Black";
FontFace[w++] = "Arial Narrow";
FontFace[w++] = "Book Antiqua";
FontFace[w++] = "Century Gothic";
FontFace[w++] = "Comic Sans MS";
FontFace[w++] = "Courier New";
FontFace[w++] = "Fixedsys";
FontFace[w++] = "Franklin Gothic Medium";
FontFace[w++] = "Garamond";
FontFace[w++] = "Lucida Console";
FontFace[w++] = "Lucida Sans Unicode";
FontFace[w++] = "Microsoft Sans Serif";
FontFace[w++] = "Palatino Linotype";
FontFace[w++] = "System";
FontFace[w++] = "Tahoma";
FontFace[w++] = "Trebuchet MS";

//Created by Agent Moose
var b = document.getElementsByTagName("select");
for(y=0;y<b.length;y++){
if(b[y].name === "font"){
for(x=0;x<FontFace.length;x++){
b[y].options[b[y].options.length] = new Option(FontFace[x],FontFace[x]);
for(p=0;p<b[y].options.length;p++){ b[y].options[p].style.fontFamily = b[y].options[p].value; };
};};};
</script>


You may add/remove fonts as you wish :)

Enjoy :)
Offline Profile Quote Post Goto Top
 
Replies:
Deleted User
Deleted User

I'm just having trouble adding new fonts
Quote Post Goto Top
 
Cory
Member Avatar
Member
[ *  *  *  *  *  *  *  *  * ]
Please post the code you tried to use and list what fonts you're trying to add.
Online Profile Quote Post Goto Top
 
Trinity76
Member Avatar
Member
[ *  * ]
Zedboards
Jul 13 2010, 09:16 AM
When I put it in our below the board, our "font" dropdown box gets a carriage return in the title. This means, when I hit Add Reply or New Topic and get the full screen, the box with the word Font in it (that you click on for the dropdown menu) has an extra blank line beneath the word Font. I took the code back out and this went away again. Any thoughts on where that is so I can take it out?

I get the same thing. The font box is twice as high as the color box.

Posted Image
Offline Profile Quote Post Goto Top
 
Cory
Member Avatar
Member
[ *  *  *  *  *  *  *  *  * ]
Admin CP Posted Image Themes Posted Image Board Template Posted Image Javascripts
Code:
 
<style type="text/css">
select[name="font"] {
height: 17px;
}
</style>
That should fix it. You can change the amount of pixels till it matches the color drop down height if it doesn't.
Online Profile Quote Post Goto Top
 
Trinity76
Member Avatar
Member
[ *  * ]
That fixed it! Thanks once again, Cory.
Offline Profile Quote Post Goto Top
 
F13rbo2
Member
[ * ]
What is a front?
Offline Profile Quote Post Goto Top
 
Cory
Member Avatar
Member
[ *  *  *  *  *  *  *  *  * ]
Font definition and information: http://en.wikipedia.org/wiki/Font
Online Profile Quote Post Goto Top
 
ShySteph
Member
[ * ]
NVM, I got it sorted, thanks for the code :)
Edited by ShySteph, Jun 14 2012, 09:19 AM.
Offline Profile Quote Post Goto Top
 
1 user reading this topic (1 Guest and 0 Anonymous)
« Previous Topic · ZetaBoards Codes & Modifications · Next Topic »
Add Reply
  • Pages:
  • 1
  • 3