Go Back   vb.org Archive > vBulletin Modifications > Archive > vB.org Archives > vBulletin 3.0 > vBulletin 3.0 Full Releases
FAQ Community Calendar Today's Posts Search

Reply
 
Thread Tools
Smilie Category Hack Details »»
Smilie Category Hack
Version: 1.00, by Pseudomizer Pseudomizer is offline
Developer Last Online: Feb 2010 Show Printable Version Email this Page

Version: 3.0.1 Rating:
Released: 05-21-2004 Last Update: 06-09-2004 Installs: 100
 
No support by the author.

Welcome to my first Release of

Smilie Category Hack or How-to-organize VB smilies in a nutshell

This small Hack helps you to organize your smilies in a better and easier way:

How does this work ?

You have to have to create multiple Smilie Categories with your ACP Smilie Manager. This hack will offer you a form select screen in your smilie popup window. So you can now easily choose from different categories.
The integration should take about 5 minutes and is very easy. But please remember that you need to have at least 2 categories created with your smiliemanager in your ACP.

Required actions:

- 1 template change
- 1 php file change

Please click on this install button or on the install button on the upper right corner if you wish to get support for this hack.

Update 1.01
Bug in the WYSIWYG editor fixed.

Enjoy it.

Cheers,

Show Your Support

  • This modification may not be copied, reproduced or published elsewhere without author's permission.

Comments
  #132  
Old 08-15-2005, 06:39 AM
Starkiller Starkiller is offline
 
Join Date: Jun 2005
Posts: 8
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by Pseudomizer
Hello Starkiller,

I do not know what you did but it should work on your site. It works on every other site. I have no idea what you did wrong especially because the install instructions are very short and you can not do much errors during the install/modifications.

Cheers,
It's not my installation it's your code. You categorized the getsmilies function used by the editor but not showsmilies one used for the posting rules. I fixed it last night by commenting out the old showsmilies and pasting in your code only renaming it. Works fine now. Sorry I hadn't gotten around to posting back on this thread to tell you I'd fixed it.
Reply With Quote
  #133  
Old 08-15-2005, 06:46 AM
Pseudomizer's Avatar
Pseudomizer Pseudomizer is offline
 
Join Date: Mar 2002
Location: Germany
Posts: 614
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by Starkiller
It's not my installation it's your code. You categorized the getsmilies function used by the editor but not showsmilies one used for the posting rules. I fixed it last night by commenting out the old showsmilies and pasting in your code only renaming it. Works fine now. Sorry I hadn't gotten around to posting back on this thread to tell you I'd fixed it.
Could you please post your changes then into this thread so I can integrate this later into my VBulletin 3.5?

Thanks in advance.

Cheers,
Reply With Quote
  #134  
Old 08-22-2005, 01:28 AM
GoTTi GoTTi is offline
 
Join Date: Jun 2002
Posts: 1,346
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

is there a way we can have random smilies being shown? for some reason im only showing 1 category.
Reply With Quote
  #135  
Old 08-22-2005, 01:29 AM
GoTTi GoTTi is offline
 
Join Date: Jun 2002
Posts: 1,346
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

im using this with 308 btw. works perfect. i would like random smilies though, like i mentioned aboved....
Reply With Quote
  #136  
Old 08-23-2005, 01:48 AM
Starkiller Starkiller is offline
 
Join Date: Jun 2005
Posts: 8
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by Pseudomizer
Could you please post your changes then into this thread so I can integrate this later into my VBulletin 3.5?

Thanks in advance.

Cheers,
Change:
PHP Code:
// ############################### start show smilies ###############################
if ($_REQUEST['do'] == 'showsmilies')
{

    
$smiliebits '';

    
$smilies $DB_site->query("
        SELECT 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, smilie.displayorder
    "
);

    while (
$smilie $DB_site->fetch_array($smilies))
    {
        if (
$smilie['category'] != $lastcat)
        {
            eval(
'$smiliebits .= "' fetch_template('help_smilies_category') . '";');
        }
        
exec_switch_bg();
        eval(
'$smiliebits .= "' fetch_template('help_smilies_smilie') . '";');
        
$lastcat $smilie['category'];
    }

    
$navbits construct_navbits(array(
        
"faq.php?$session[sessionurl]=> $vbphrase['faq'],
        
'' => $vbphrase['smilie_list']
    ));

    eval(
'$navbar = "' fetch_template('navbar') . '";');

    eval(
'print_output("' fetch_template('help_smilies') . '");');

to:
PHP Code:
// ############################### start show smilies ###############################
if ($_REQUEST['do'] == 'showsmilies')
{
    
globalize($_REQUEST, array('wysiwyg' => INT'getsmilies' => STR_NOHTML));

    
$show['wysiwyg'] = $wysiwyg;

    
$smilies $DB_site->query("
        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, smilie.displayorder
    "
);

    
$smcache = array();
    while (
$smilie $DB_site->fetch_array($smilies))
    {
        
$smcache["$smilie[category]"][] = $smilie;
        
//echo $smilie[category];
    
}

    
$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>";

    
$popup_smiliesbits '';
    
$bits = array();
    
exec_switch_bg();
    foreach (
$smcache AS $category => $smilies)
    {
      if ( 
$category == $select_category )
      {
        if (
sizeof($bits) == 1)
        {
            eval(
'$smiliecells = "' fetch_template('smiliepopup_straggler') . '";');
            eval(
'$smiliebits .= "' fetch_template('smiliepopup_row') . '";');
        }
        
// eval('$smiliebits .= "' . fetch_template('smiliepopup_category') . '";');
        
$bits = array();
        foreach (
$smilies AS $smilie)
        {
            
$smilie['js'] = addslashes($smilie['text']);
            eval(
'$bits[] = "' fetch_template('smiliepopup_smilie') . '";');
            if (
sizeof($bits) == 2)
            {
                
exec_switch_bg();
                
$smiliecells implode(''$bits);
                eval(
'$smiliebits .= "' fetch_template('smiliepopup_row') . '";');
                
$bits = array();
            }
        }
       }
       else
       {
           
//do nothing
       
}
    }
    if (
sizeof($bits) == 1)
    {
        eval(
'$smiliecells = "' fetch_template('smiliepopup_straggler') . '";');
        eval(
'$smiliebits .= "' fetch_template('smiliepopup_row') . '";');
    }

    unset(
$shutdownqueries['pmpopup']);
    eval(
'print_output("' fetch_template('smiliepopup') . '");');

}

/*if ($_REQUEST['do'] == 'showsmilies')
{

    $smiliebits = '';

    $smilies = $DB_site->query("
        SELECT 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, smilie.displayorder
    ");

    while ($smilie = $DB_site->fetch_array($smilies))
    {
        if ($smilie['category'] != $lastcat)
        {
            eval('$smiliebits .= "' . fetch_template('help_smilies_category') . '";');
        }
        exec_switch_bg();
        eval('$smiliebits .= "' . fetch_template('help_smilies_smilie') . '";');
        $lastcat = $smilie['category'];
    }

    $navbits = construct_navbits(array(
        "faq.php?$session[sessionurl]" => $vbphrase['faq'],
        '' => $vbphrase['smilie_list']
    ));

    eval('$navbar = "' . fetch_template('navbar') . '";');

    eval('print_output("' . fetch_template('help_smilies') . '");');
}*/ 
Reply With Quote
  #137  
Old 08-23-2005, 01:55 AM
amykhar's Avatar
amykhar amykhar is offline
 
Join Date: Oct 2001
Location: PA
Posts: 4,438
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Offer removed.
Reply With Quote
  #138  
Old 09-12-2005, 04:29 AM
sinaluna sinaluna is offline
 
Join Date: Feb 2005
Posts: 93
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

amykhar: I'm unable to find this hack on your forum. Your link to mods takes me to an error page. ???
Reply With Quote
  #139  
Old 09-12-2005, 05:12 PM
Quillz's Avatar
Quillz Quillz is offline
 
Join Date: Jan 2005
Location: Los Angeles, CA
Posts: 128
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Nice hack. I may use it in the future.
Reply With Quote
  #140  
Old 10-03-2005, 10:27 PM
Bubble #5 Bubble #5 is offline
 
Join Date: Apr 2005
Posts: 984
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by amykhar
I have a 3.5 - style one done and posted on my website if anybody needs to get it. it's freely available for those who need it.
Actually it's not. When you click on any of the links you get an error message saying it's "not a public forum". Even when you click on the link to contact you this same error message pops up

That's the only reason why we came here looking for a hack like this. Otherwise we would have used yours.

Sinaluna I feel your pain
Reply With Quote
  #141  
Old 10-03-2005, 11:28 PM
Pseudomizer's Avatar
Pseudomizer Pseudomizer is offline
 
Join Date: Mar 2002
Location: Germany
Posts: 614
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Hello,

just to make it clear here, that I will release an update for the 3.5 version but due to my current relocation to US (within my company) I will not be able to work on this until November.

So you should expect an update end of November or December 2005!

Cheers,
Reply With Quote
Reply


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT. The time now is 04:51 AM.


Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.05295 seconds
  • Memory Usage 2,361KB
  • Queries Executed 25 (?)
More Information
Template Usage:
  • (1)SHOWTHREAD
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (1)ad_showthread_beforeqr
  • (2)bbcode_php
  • (4)bbcode_quote
  • (1)footer
  • (1)forumjump
  • (1)forumrules
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (1)modsystem_post
  • (1)navbar
  • (6)navbar_link
  • (120)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (4)pagenav_pagelink
  • (1)pagenav_pagelinkrel
  • (11)post_thanks_box
  • (11)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (11)post_thanks_postbit_info
  • (10)postbit
  • (11)postbit_onlinestatus
  • (11)postbit_wrapper
  • (1)spacer_close
  • (1)spacer_open
  • (1)tagbit_wrapper 

Phrase Groups Available:
  • global
  • inlinemod
  • postbit
  • posting
  • reputationlevel
  • showthread
Included Files:
  • ./showthread.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/functions_bigthree.php
  • ./includes/class_postbit.php
  • ./includes/class_bbcode.php
  • ./includes/functions_reputation.php
  • ./includes/functions_post_thanks.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • showthread_start
  • showthread_getinfo
  • forumjump
  • showthread_post_start
  • showthread_query_postids
  • showthread_query
  • bbcode_fetch_tags
  • bbcode_create
  • showthread_postbit_create
  • postbit_factory
  • postbit_display_start
  • post_thanks_function_post_thanks_off_start
  • post_thanks_function_post_thanks_off_end
  • post_thanks_function_fetch_thanks_start
  • post_thanks_function_fetch_thanks_end
  • post_thanks_function_thanked_already_start
  • post_thanks_function_thanked_already_end
  • fetch_musername
  • postbit_imicons
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • postbit_display_complete
  • post_thanks_function_can_thank_this_post_start
  • pagenav_page
  • pagenav_complete
  • tag_fetchbit_complete
  • forumrules
  • navbits
  • navbits_complete
  • showthread_complete