Thanks Jake.
Merry Christmas to you!
Announcement
Collapse
No announcement yet.
What .js file controls the clickable smilies?
Collapse
X
-
The includes/functions_editor.php file has a bunch of smilie code:
Code:if ($editor_type == 'qr') { // no smilies } else if ($allowsmilie AND $show['editor_toolbar']) { // deal with disable smilies option if (!isset($checked['disablesmilies'])) { $vbulletin->input->clean_gpc('r', 'disablesmilies', TYPE_BOOL); $checked['disablesmilies'] = iif($vbulletin->GPC['disablesmilies'], 'checked="checked"'); } eval('$disablesmiliesoption = "' . fetch_template('newpost_disablesmiliesoption') . '";'); if ($toolbartype AND ($vbulletin->options['smtotal'] > 0 OR $vbulletin->options['wysiwyg_smtotal'] > 0)) { // query smilies $smilies = $vbulletin->db->query_read_slave(" SELECT smilieid, smilietext, smiliepath, smilie.title, imagecategory.title AS category FROM " . TABLE_PREFIX . "smilie AS smilie LEFT JOIN " . TABLE_PREFIX . "imagecategory AS imagecategory USING(imagecategoryid) ORDER BY imagecategory.displayorder, imagecategory.title, smilie.displayorder "); // get total number of smilies $totalsmilies = $vbulletin->db->num_rows($smilies); if ($totalsmilies > 0) { if ($vbulletin->options['wysiwyg_smtotal'] > 0) { $show['wysiwygsmilies'] = true; // smilie dropdown menu $vBeditJs['smilie_options_array'] = array(); $i = 0; while ($smilie = $vbulletin->db->fetch_array($smilies)) { if (empty($prevcategory)) { $prevcategory = $smilie['category']; } if ($i++ < $vbulletin->options['wysiwyg_smtotal']) { $vBeditJs['smilie_options_array']["$smilie[category]"][] = "\t\t'$smilie[smilieid]' : new Array('" . addslashes_js($smilie['smiliepath']) . "', '" . addslashes_js($smilie['smilietext']) . "', '" . addslashes_js($smilie['title']) . "')"; } else { $vBeditJs['smilie_options_array']["$prevcategory"][] = "\t\t'more' : '" . addslashes_js($vbphrase['show_all_smilies']) . "'\n"; break; } $prevcategory = $smilie['category']; } foreach (array_keys($vBeditJs['smilie_options_array']) AS $category) { $vBeditJs['smilie_options_array']["$category"] = "\t'" . addslashes_js($category) . "' : {\n" . implode(",\n", $vBeditJs['smilie_options_array']["$category"]) . "}"; } $vBeditJs['smilie_options_array'] = "\n" . implode(",\n", $vBeditJs['smilie_options_array']); } else { $show['wysiwygsmilies'] = false; } // clickable smilie box if ($vbulletin->options['smtotal']) { $vbulletin->db->data_seek($smilies, 0); $i = 0; $bits = array(); while ($smilie = $vbulletin->db->fetch_array($smilies) AND $i++ < $vbulletin->options['smtotal']) { $smiliehtml = "<img src=\"$smilie[smiliepath]\" id=\"{$editorid}_smilie_$smilie[smilieid]\" alt=\"" . htmlspecialchars_uni($smilie['smilietext']) . "\" title=\"$smilie[title]\" border=\"0\" />"; eval('$bits[] = "' . fetch_template('editor_smilie') . '";'); if (sizeof($bits) == $vbulletin->options['smcolumns']) { $smiliecells = implode('', $bits); eval('$smiliebits .= "' . fetch_template('editor_smiliebox_row') . '";'); $bits = array(); } } // fill in empty cells if required $remaining = sizeof($bits); if ($remaining > 0) { $remainingcolumns = $vbulletin->options['smcolumns'] - $remaining; eval('$bits[] = "' . fetch_template('editor_smiliebox_straggler') . '";'); $smiliecells = implode('', $bits); eval('$smiliebits .= "' . fetch_template('editor_smiliebox_row') . '";'); } $show['moresmilieslink'] = iif ($totalsmilies > $vbulletin->options['smtotal'], true, false); $show['smiliebox'] = true; } $vbulletin->db->free_result($smilies); } } eval('$smiliebox = "' . fetch_template('editor_smiliebox') . '";'); }
clientscript/vbulletin_global.js
clientscript/vbulletin_menu.js
I don't see any others.
I wasn't able to find specific javascript code. If you need help with specific code I recommend you post on www.vbulletin.org.
Leave a comment:
-
What .js file controls the clickable smilies?
We have over 500 smilies loaded and opening the full list is giving certain IE installs seizures.
Can someone tell me which .js file this is controlled in? I have a programmer helping my peeps troubleshoot and he would like to take a look.
Thanks!Tags: None
widgetinstance 262 (Related Topics) skipped due to lack of content & hide_module_if_empty option.
Leave a comment: