is there a font changing item or how I would I make the changes to make one?
Add a new Display Name CSS item to your forum. For the style, do something like
font-family: <name of the font>
For example
font-family: Georgia
Ok I tried to make this using another item but it didnt change the font, it did nothing.
When you go to use the item,there is a dropdown box with 5 fonts - displaying in the actual fonts - but when I use it, it does nothing.
I am posting the code I have, I used the change style item and changed stuff to 'font' but I dont know how to code so its probably missing something important:
<?php
/**********************************************\
| SMFSHOP (Shop MOD for Simple Machines Forum) |
| (c) 2005 DanSoft Australia |
| http://www.dansoftaustralia.net/ |
\**********************************************/
//File: Change_Font.php
//This item allows users to change their name font using a drop down menu.
//NOTE: This item requires that the DisplayNameCSS addon item be installed!
//Authors Website: www.graphicaddicts.net
//VERSION: 1.0
//DATE: April 21st 2006
class item_Change_Font extends itemTemplate {
function getItemDetails() {
$this->name = "Change Name Font!";
$this->desc = "Change the font of your display name to: Arial, Comic Sans, Courier, Papyrus, Times, Verdana.";
$this->price = 75;
$this->require_input = true;
$this->can_use_item = true;
}
function getUseInput() {
return 'Select a Font: <select name="font_" size="1" id="color">
<option value="font-family: Arial" style="font-family: Arial">Arial</option>
<option value="font-family: Comic Sans MS" style="font-family: Comic Sans MS">Comic Sans MS</option>
<option value="font-family: Courier New" style="font-family: Courier New">Courier New</option>
<option value="font-family: Papyrus" style="font-family: Papyrus">Papyrus</option>
<option value="font-family: Times New Roman" style="font-family: Times New Roman">Times New Roman</option>
<option value="font-family: Verdana" style="font-family: Verdana">Verdana</option>
</select>';
}
function onUse() {
global $db_prefix, $ID_MEMBER;
$result = db_query("UPDATE {$db_prefix}members
SET shop_nameStyle =
concat(shop_nameStyle,'{$_POST['font_']};')
WHERE ID_MEMBER = {$ID_MEMBER}",
__FILE__, __LINE__);
return "Successfully updated your display name font!";
}
}
?>
Sorry but I dont know how to make it work