- Code: Select all
loadSmileyBox: function()
{
var container = $('pfc_smileys');
var smileys = pfc.res.getSmileyReverseHash();//getSmileyHash();
var sl = smileys.keys();
for(var i = 0; i < sl.length; i++)
{
s_url = sl[i];
s_symbol = smileys[sl[i]];
s_symbol = s_symbol.unescapeHTML();
var img = document.createElement('img');
img.setAttribute('src', s_url);
img.setAttribute('alt', s_symbol);
img.setAttribute('title', s_symbol);
img.s_symbol = s_symbol;
img.onclick = function(){ pfc.insertSmiley(this.s_symbol); }
container.appendChild(img);
container.appendChild(document.createTextNode(' ')); // so smileys will wrap fine if lot of smiles in theme.
BTW, the "oops" tag is "<oops>". Shouldn't it be ":oops:" to be consistent with the rest?