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

Reply
 
Thread Tools
Details »»

Version: , by Admin (Coder) Admin is offline
Developer Last Online: Nov 2024 Show Printable Version Email this Page

Version: 2.2.x Rating:
Released: 08-19-2001 Last Update: Never Installs: 75
 
No support by the author.

Description:
This hack will allow you to set the display order of clickable smilies (if you use them).
It's good if you have a lot of smilies, and want the more commonly used to be shown in the box.

Demo:


Installation:
1. Run the following queries either in phpMyAdmin or thru Telnet: (one query at a time)
Code:
ALTER TABLE smilie ADD showid SMALLINT not null
ALTER TABLE smilie ADD INDEX (showid)
UPDATE smilie SET showid=smilieid
2. In functions.php (in your admin folder) replace
PHP Code:
$smilies $DB_site->query("SELECT title, smilietext, smiliepath FROM smilie"); 
with
PHP Code:
$smilies $DB_site->query("SELECT title, smilietext, smiliepath FROM smilie ORDER BY showid"); 
And also replace
PHP Code:
$smilies=$DB_site->query("SELECT smilietext,smiliepath FROM smilie"); 
with
PHP Code:
$smilies=$DB_site->query("SELECT smilietext,smiliepath FROM smilie ORDER BY showid"); 
3. In smilie.php (in your admin folder) replace
PHP Code:
$smilies=$DB_site->query("SELECT smilietext,smilieid,title,smiliepath FROM smilie ORDER BY title LIMIT ".($limitlower-1).",$perpage"); 
with
PHP Code:
$smilies=$DB_site->query("SELECT smilietext,smilieid,title,smiliepath,showid FROM smilie ORDER BY showid LIMIT ".($limitlower-1).",$perpage"); 
Below
PHP Code:
echo makelinkcode("remove","smilie.php?s=$session[sessionhash]&action=remove&smilieid=$smilie[smilieid]&perpage=$perpage&statrpage=$startpage"); 
add
PHP Code:
echo "<br>Order: <input type=text name=\"order[$smilie[smilieid]]\" size=5 value=\"$smilie[showid]\">"
Replace
PHP Code:
echo "</table></td></tr></table></form>"
with
PHP Code:
doformfooter("Update order"); 
Replace
PHP Code:
doformheader("smilie","modify"); 
with
PHP Code:
doformheader("smilie","doorder"); 
Above
PHP Code:
// ###################### Start Modify ####################### 
add
PHP Code:
// ###################### Start do order #####################
if ($HTTP_POST_VARS['action']=="doorder") {

  while (list(
$key,$val)=each($order)) {

    
$DB_site->query("UPDATE smilie SET showid='$val' WHERE smilieid='$key'");

  }

  echo 
"<p>Order updated!</p>";
  
$action="modify";


Requested by:
JJR512

That's it! Feedback, requests and anything else is more than welcome.
Good luck!

Show Your Support

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

Comments
  #132  
Old 12-17-2002, 11:51 PM
AzzKickr's Avatar
AzzKickr AzzKickr is offline
 
Join Date: Sep 2002
Posts: 16
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

hi guys. is it possible to make this:
first 6 smilies will always be here and i will setup it using this hack, and other 6 will check random using random smilies hack :chinese:
sorry my bad english
Reply With Quote
  #133  
Old 01-06-2003, 12:51 AM
Dan_UPC Dan_UPC is offline
 
Join Date: Dec 2002
Posts: 49
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Thanks for a great hack Firefly.

*Installs*
Reply With Quote
  #134  
Old 02-05-2003, 08:50 PM
Oblivion Knight's Avatar
Oblivion Knight Oblivion Knight is offline
 
Join Date: May 2002
Location: Sheffield, UK
Posts: 1,757
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Top stuff FireFly.
Nice and simple, yet really handy

[high]* Oblivion Knight clicks install.[/high]
Reply With Quote
  #135  
Old 02-10-2003, 09:33 PM
Host Directory Host Directory is offline
 
Join Date: Feb 2003
Posts: 82
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I have been looking for a hack which does not seem to exist, this is kind of on the same lines so i am hoping you might be interested in this hack.

New area in admin panel.

Allows you to set the smilies in Posts to be displayed ramdomly or pick the ones you wish from your smilies list to display in the New Post area.

Also allows option to display smilies in Get More as ramdom but also allows you to select how many smilies should appear in Get More before splitting the page.

For example if you have 400 smilies and you set the number to split at 50. The result would be 8 seperate pages with the smilies on.

This is much better - i have lots of smilies and they all display on one page. Many of the smilies i have are animated and the server cannot cope with so many on one page. I think a lot of people have this problem. The result is many of the smilies do not show as a graphic.

This would be a good hack to make.
Reply With Quote
  #136  
Old 02-15-2003, 04:48 PM
Host Directory Host Directory is offline
 
Join Date: Feb 2003
Posts: 82
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Can someone do me a massive favour and talk me through phpmyadmin - i am confused how to change the code.

I need to

Quote:
ALTER TABLE smilie ADD showid SMALLINT not null
ALTER TABLE smilie ADD INDEX (showid)
UPDATE smilie SET showid=smilieid
I have never used phpmyadmin before. Can someone talk me through?
Reply With Quote
  #137  
Old 02-17-2003, 01:54 PM
Host Directory Host Directory is offline
 
Join Date: Feb 2003
Posts: 82
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I have installed this now and its working fine on 2.2.9

Someone has told me that this hack wont work on the new version of vb 2.3.0.

Can anyone confirm this before i upgrade?
Reply With Quote
  #138  
Old 02-21-2003, 06:16 PM
Paraone Paraone is offline
 
Join Date: Feb 2003
Posts: 14
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

EDIT: I JUST NOTICED THE POST ABOVE MINE!!!! I have version 2.3.0 and I can't get it to work, can "DA MAN" make one that works for the newest version ppppplease please please...!!! If not I understand..... now read my post, it may help you fix whatever problem it is having...

Ok i got this error:

Parse error: parse error in /home/clan-tuc/public_html/forums/admin/functions.php on line 865

Fatal error: Call to undefined function: vbdate() in /home/clan-tuc/public_html/forums/admin/sessions.php on line 400

after the 1st post install....so i put the old backup of functions back in...and the site came back up, tried it all again and same error...

Ok so then i downloaded the orsmin file...and the first link worked, but the second gave an error...so i ran the first again...then installed everything and same error...so i replaced the functions.php with the original copy and the sites backup(still the modified smilie.php)

so just for the hell of it, i went into admin...and now i have numbers below the smilies...so i tried changing the order, and it didn't work, obviously cuz i don't have the proper stuff in the functions.php....

Now when i ran the mysql queries...the last query didn't reply with ran succesful it just said :

Affected rows: 0

SQL-query : [Edit] [Create PHP Code]
UPDATE smilie SETshowid = smilieid

but i get that error....ne ideas whats going on
Reply With Quote
  #139  
Old 03-09-2003, 09:15 AM
Cyricx Cyricx is offline
 
Join Date: Aug 2002
Location: Missouri
Posts: 1,144
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

not getting the error codes but it definately isn't working for me, I'm on 2.3.0

it won't display their current order number or accept changes well, they get all fubared and contorted for the order lol.

No discernable pattern that I can find.
Reply With Quote
  #140  
Old 03-09-2003, 04:55 PM
Paraone Paraone is offline
 
Join Date: Feb 2003
Posts: 14
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

well i wonder if we can get this working on 2.3.0 ...who is a super hacker that can figure it out?
Reply With Quote
  #141  
Old 03-14-2003, 06:49 PM
AllMadden.net AllMadden.net is offline
 
Join Date: Mar 2003
Location: New York
Posts: 16
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

It seems to work on 2.3 for me...but when I try to edit the smilies or add or upload in the admin menu I get this error:

Parse error: parse error, unexpected ':' in /home/virtual/site4/fst/var/www/html/madden/forums/admin/smilie.php on line 268

Any idea how to fix that?
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 08:48 PM.


Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2024, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.07365 seconds
  • Memory Usage 2,337KB
  • 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
  • (1)bbcode_code
  • (14)bbcode_php
  • (1)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