SpiderFive |
01-31-2006 05:39 PM |
Hello this is a workarround for the Problem..
There ist a one problem you must use drag and drop bei using the smilies.
I hope of a new release ..., or help of one of the cracks
3 changes
1 file
2 templates
Edit the misc.php in your forum root
change the whole code of the this section
PHP Code:
// ############################### Popup Smilies for vbCode ################
....
with this
PHP Code:
// ############################### Popup Smilies for vbCode ################
if ($_REQUEST['do'] == 'getsmilies')
{
$editorid = $vbulletin->input->clean_gpc('r', 'editorid', TYPE_NOHTML);
($hook = vBulletinHook::fetch_hook('misc_smiliespopup_start')) ? eval($hook) : false;
$smilies = $db->query_read("
SELECT smilietext AS text, smiliepath AS path, smilie.title, smilieid,
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
");
$smcache = array();
while ($smilie = $db->fetch_array($smilies))
{
$smcache["{$smilie['category']}"][] = $smilie;
}
//##### start of the hack ##################
$i = "0";
foreach ($smcache AS $category => $smilies)
{
$new_categories[$i] = $category;
$i++;
}
if (!$_REQUEST['select_category'])
{
$select_category = $new_categories[0];
}
else
{
$select_category = $_REQUEST['select_category'];
}
$new_smilies .= "<form name=\"smilieform\" action=\"misc.php\">";
$new_smilies .= "<input type=\"hidden\" name=\"do\" value=\"getsmilies\">";
$new_smilies .= "<input type=\"hidden\" name=\"wysiwyg\" value=\"$wysiwyg\">";
$new_smilies .= "<select name=\"select_category\" size=\"1\"><option value=\"\">Click to select";
foreach ($new_categories AS $input)
{
$add_select .= "<option value=\"".$input."\">$input";
}
$new_smilies .= $add_select;
$new_smilies .= "</select><input type=\"submit\" value=\"Go!\"\"></form></center>";
$new_smilies .= "<BR><Font face=\"arial,helvetica\">".$select_category."<BR><BR></Font>";
//##### end of the hack ##################
$popup_smiliesbits = '';
$bits = array();
exec_switch_bg();
foreach ($smcache AS $category => $smilies)
{
//#### start of added supplements to the program code ####
if ($category == $select_category)
{
//#### end of added supplements to the program code ####
if (sizeof($bits) == 1)
{
eval('$smiliecells = "' . fetch_template('smiliepopup_straggler') . '";');
eval('$smiliebits .= "' . fetch_template('smiliepopup_row') . '";');
}
($hook = vBulletinHook::fetch_hook('misc_smiliespopup_category')) ? eval($hook) : false;
eval('$smiliebits .= "' . fetch_template('smiliepopup_category') . '";');
$bits = array();
foreach ($smilies AS $smilie)
{
($hook = vBulletinHook::fetch_hook('misc_smiliespopup_smilie')) ? eval($hook) : false;
$smilie['js'] = addslashes_js($smilie['text']);
$smiliehtml = "<img src=\"$smilie[path]\" id=\"smilie_$smilie[smilieid]\" alt=\"" . htmlspecialchars_uni($smilie['text']) . "\" title=\"$smilie[title]\" />";
eval('$bits[] = "' . fetch_template('smiliepopup_smilie') . '";');
if (sizeof($bits) == 2)
{
exec_switch_bg();
$smiliecells = implode('', $bits);
eval('$smiliebits .= "' . fetch_template('smiliepopup_row') . '";');
$bits = array();
}
}
// #### start of added supplements to the program code ####
}
// #### end of added supplements to the program code ####
}
if (sizeof($bits) == 1)
{
eval('$smiliecells = "' . fetch_template('smiliepopup_straggler') . '";');
eval('$smiliebits .= "' . fetch_template('smiliepopup_row') . '";');
}
($hook = vBulletinHook::fetch_hook('misc_smiliespopup_complete')) ? eval($hook) : false;
eval('print_output("' . fetch_template('smiliepopup') . '");');
}
$vbulletin->input->clean_gpc('r', 'template', TYPE_NOHTML);
In Template Forumrules
search
PHP Code:
<div><phrase 1="misc.php?$session[sessionurl]do=showsmilies" 2="$smilieson">$vbphrase[smilies_are_x]</phrase></div>
an change ist with this code
PHP Code:
<div><phrase 1="misc.php?$session[sessionurl]do=getsmilies&wysiwyg=1" 2="$smilieson">$vbphrase[smilies_are_x]</phrase></div>
In Template smiliepopup
Search and add under this
PHP Code:
$headinclude
</head>
<body style="margin:0px" onload="self.focus()">
add:
|