Go Back   vb.org Archive > vBulletin Modifications > Archive > vB.org Archives > vBulletin 2.x > vBulletin 2.x Full Releases

Reply
 
Thread Tools
Custom Postbit for every User Details »»
Custom Postbit for every User
Version: 1.00, by Xenon Xenon is offline
Developer Last Online: Oct 2023 Show Printable Version Email this Page

Version: 2.2.x Rating:
Released: 09-17-2002 Last Update: Never Installs: 29
 
No support by the author.

After the one Day Beta-Version i've finished the Hack so i can release it now.

Hack Version: 1.20b

Additional Queries in showthread.php: 1

What it does: It gives users the Ability to choose between custom postbits instead of just the one global postbit (or more if you have different styles).
Also it allows users to create their own custom postbits using html-code (These must be validated by an admin before they can use them)
It also gives you the ability to create a postbit just a special usergroup or just a special user can use.

I think i've tested every little option, but if you find a bug please tell me.

Please click install if you use the hack.

Some additions:
in cpostbit.php you find this lines to allow users wether to choose a custom postbit or to create new ones:
// Usergroups which can use custom postbits
$canusecpb="2 5 7 6";
// Usergroups which can create own custom postbits
$cancreatecpb="2 5 7 6";

people who installed the beta version should run installcpb.php?action=unstall&killbeta=1 before installing the hack.

Enjoy
screenshots following

Show Your Support

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

Comments
  #42  
Old 02-17-2003, 09:26 PM
Xenon's Avatar
Xenon Xenon is offline
 
Join Date: Oct 2001
Location: Bavaria
Posts: 12,878
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default


glad to hear
Reply With Quote
  #43  
Old 02-23-2003, 10:44 AM
NuclioN's Avatar
NuclioN NuclioN is offline
 
Join Date: Aug 2002
Posts: 955
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Xenon, when you have the arcade hack installed the line in functions.php is:

function getpostbit($post,$vpa_champs=0) {

In that case would:
function getpostbit($post,$postbitid=0,$vpa_champs=0) {

The right way to place the code?
Reply With Quote
  #44  
Old 02-23-2003, 11:30 AM
Xenon's Avatar
Xenon Xenon is offline
 
Join Date: Oct 2001
Location: Bavaria
Posts: 12,878
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

hmm, not sure, it depends on how the arcade hack calls the postbits.

normally you are right, but you could get problems....
be sure to check every call of the getpostbitfunction, that the syntax isn't wrong anywhere...
Reply With Quote
  #45  
Old 02-23-2003, 11:46 AM
NuclioN's Avatar
NuclioN NuclioN is offline
 
Join Date: Aug 2002
Posts: 955
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

In showthread.php is an instance of the same code,

$postbits .= getpostbit($post,$vpa_champs_a);

that (should) be:

$postbits .= getpostbit($post,$postbitid=0,$vpa_champs_a); ?

I've test it and there are no errors, however when i make an adjustment or replacement it does not update it. Also after validation there is no change with the original standard postbit.
Reply With Quote
  #46  
Old 02-23-2003, 11:59 AM
NuclioN's Avatar
NuclioN NuclioN is offline
 
Join Date: Aug 2002
Posts: 955
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

In functions.php there's also this:

eval("\$retval = \"".gettemplate("postbit")."\";");
} else if ($bbuserinfo['usergroupid']!=12) {
eval("\$retval = \"".gettemplate("postbit_banned")."\";");
} else {
eval("\$retval = \"".gettemplate("postbit")."\";");
}
} else {
eval("\$retval = \"".gettemplate("postbit")."\";");
}
}
return $retval;
}

That's part of "stealth ban" hack so there are 3 instances of:
eval("\$retval = \"".gettemplate("postbit")."\";");

I like this hack Xenon but it looks that it's not for me this time.
Reply With Quote
  #47  
Old 02-23-2003, 06:47 PM
Xenon's Avatar
Xenon Xenon is offline
 
Join Date: Oct 2001
Location: Bavaria
Posts: 12,878
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

well, yes it's hard to implement it, when you already have hacked the getpostbit in your way..

the first things seemed right, so maybe you can achieve it so it works correctly.

last question: hmm, replace every instance
Reply With Quote
  #48  
Old 02-23-2003, 07:17 PM
sonic3d's Avatar
sonic3d sonic3d is offline
 
Join Date: Jan 2002
Location: Chicago
Posts: 301
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally posted by Xenon
@sonic3d and all others:
gzip compression produces that problem
i've uploaded a new version. there were just changes to admincpb.php so just upload this..
thanx a lot will try later today or tomorrow

l8er
sonic
Reply With Quote
  #49  
Old 02-24-2003, 04:51 AM
vdinh vdinh is offline
 
Join Date: Feb 2002
Posts: 35
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Hi Xenon,

I am currently running vBulletin 2.2.9. On some of the old threads, whenever I tried to get to the first page, it gave me an error such as:

---------------------------
Database error in vBulletin 2.2.9:

Invalid SQL: SELECT * FROM custompostbit WHERE postbitid IN (0,0,0,0,0,0,0,0,0,,0,0,0,,,0,,0,,0,,0,0,,0,,0,0,0 ,0,0,0,0,0,0,0,0,0,0,0,0)
mysql error: You have an error in your SQL syntax near '0,0,0,,,0,,0,,0,,0,0,,0,,0,0,0,0,0,0,0,0,0,0,0,0, 0,0,0)' at line 1
mysql error number: 1064

Date: Sunday 23rd of February 2003 04:48:45 PM
Script: http://myvbulletin.com/vb...mp;threadid=903
Referer: http://myvbulletin.com/vbulleti...=&forumid=3
------------------------------

The thing is if I click to to to page 2 of those thread, it worked as normal. So what is the problem and how can I fix it ? Please enlighten me

Thanks a lot.
Reply With Quote
  #50  
Old 02-24-2003, 10:05 AM
Xenon's Avatar
Xenon Xenon is offline
 
Join Date: Oct 2001
Location: Bavaria
Posts: 12,878
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

huh?

that error never occured to me.

have you made an error while installing?

if not i need more informations, what is different between the first page and the second one?
Reply With Quote
Reply

Thread Tools

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 12:25 AM.


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.04612 seconds
  • Memory Usage 2,281KB
  • Queries Executed 24 (?)
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_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
  • (2)pagenav_pagelink
  • (10)post_thanks_box
  • (10)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (10)post_thanks_postbit_info
  • (9)postbit
  • (10)postbit_onlinestatus
  • (10)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