SmartFAQ is developed by The SmartFactory (, a division of InBox Solutions (

How do I manage smilies?
Requested and Answered by Carnuke on 2005/2/27 21:59:09 (8661 reads)
You can add more smilies to your system using the form at the bottom of the page (there are many websites where you can obtain new ones). Simply enter a shortcut code for your new smile (this should be unique), a name for it, select the file you want to upload using the browse button, and decide whether or not you want it to be one of those displayed on submission forms. Select submit to upload it. Clicking on the edit link for an existing smarty will open up a form with the same options. You can even replace the image file if you want.

The comments are owned by the author. We aren't responsible for their content.
  • Just popping in

 Smiley Icons pushed the table wider - a way to fix

When you reply a post or add new comment, you like to use smiley, right? The standard smiley in the XOOPS is a 9-icon row plus [more...] format, now you want more smilies.

Yes I always love the smilies, but when I added more, I immediately found the input form(s) got pushed wider and wider because of the codes that holds smiley does not have a space "in-between" icons, this is a very simple issue but there are TWO files need to modify so you got a clean, auto-wrap smilies page according to your layout/table width, modify two files fit to all forms.

1. root


BACKUP first as usual, then find

$ret "<a name='moresmiley'></a><img onmouseover=

change to
$ret " <a name='moresmiley'></a> <img onmouseover=


$ret .= "<img onclick='xoopsCodeSmilie("".$this->getName()."", " ".$smiles['code']." ");' onmouseover='style.cursor="hand"' src='".XOOPS_UPLOAD_URL."/".htmlspecialchars($smiles['smile_url'], ENT_QUOTES)."' alt='' />";

change to

$ret .= " <img onclick='xoopsCodeSmilie("".$this->getName()."", " ".$smiles['code']." ");' onmouseover='style.cursor="hand"' src='".XOOPS_UPLOAD_URL."/".htmlspecialchars($smiles['smile_url'], ENT_QUOTES)."' alt='' />  ";


$ret .= "<img onclick='xoopsCodeSmilie("".$this->getName()."", " ".$smiles[$i]['code']." ");' onmouseover='style.cursor="hand"' src='".XOOPS_UPLOAD_URL."/".$myts->oopsHtmlSpecialChars($smiles['smile_url'])."' border='0' alt='' />";

change to

$ret .= " <img onclick='xoopsCodeSmilie("".$this->getName()."", " ".$smiles[$i]['code']." ");' onmouseover='style.cursor="hand"' src='".XOOPS_UPLOAD_URL."/".$myts->oopsHtmlSpecialChars($smiles['smile_url'])."' border='0' alt='' /> ";


$ret .= "&nbsp;[<a href='#moresmiley' onclick='javascript:openWithSelfMain("".XOOPS_URL."/misc.php?action=showpopups&type=smilies&target=".$this->getName()."","smilies",300,475);'>"._MORE."</a>]";

change to

$ret .= "&nbsp; [<a href='#moresmiley' onclick='javascript:openWithSelfMain("".XOOPS_URL."/misc.php?action=showpopups&type=smilies&target=".$this->getName()."","smilies",300,475);'>"._MORE."</a>] ";

2. Root


echo "<img src='".XOOPS_UPLOAD_URL."/".htmlspecialchars($smiles['smile_url'])."' border='0' onmouseover='style.cursor="hand"' alt='' onclick='xoopsCodeSmilie("".$textarea_id."", " ".$smiles['code']." ");' />";

change to

echo " <img src='".XOOPS_UPLOAD_URL."/".htmlspecialchars($smiles['smile_url'])."' border='0' onmouseover='style.cursor="hand"' alt='' onclick='xoopsCodeSmilie("".$textarea_id."", " ".$smiles['code']." ");' /> ";

..... and ... not done yet for #2, read:

well, basically you do the exactly same things in the step 1 for the step 2, save and upload them, you smiley faces should now fit to ALL forms width that have the smiley sections on it and won't push your layout out of control!!

  • Just popping in

 adding smilies