The Arcive of Official vBulletin Modifications Site.It is not a VB3 engine, just a parsed copy! |
|
#1
|
||||
|
||||
![]()
Well, as I'm still very new to PHP, I have a little question.
I find many RPG hacks and such, but what I want is something very simple and yet, I can't find it anywhere. I only want a new stat in the postbit: Level: and it has to give the amounth of posts divided by 50 Can anyone tell me how to make such 'hack' ? Thanks ^_^ |
#2
|
||||
|
||||
![]()
anybody ?
please ?? |
#3
|
||||
|
||||
![]()
I am sort of new at this stuff too, but I think the following should work:
In your admin directory in functions.php (back up functions.php before editing it) find: PHP Code:
Insert before it: PHP Code:
PHP Code:
|
#4
|
||||
|
||||
![]()
Lol what an excellently simple hack
![]() - miSt |
#5
|
||||
|
||||
![]()
Thanks man !
It works perfectly ! (I did have to leave out the +1 though ![]() But I do have a question: Hwo do you know where you have to add such code in the functions.php file ? And don't tease us, Mist ^_^ Everybody starts somewhere. We might just be the future's great hackers ![]() And besides, the little hacks can be most fun ![]() |
#6
|
||||
|
||||
![]()
How did I know where to add it? Well, I first looked at showthread.php to find out how posts are displayed. Then, I saw a call to the getpostbit function. This function was called for each post in the thread, so I figured that is where all of the variables and calculations were done. So I went to functions.php and found the getpostbit function. As far as where to put it in the getpostbit function, I just decided to skim to the bottom since all of the other stuff didn't pertain to or affect what I was trying to do. However, it would have been pointless to put it at the very bottom of the getpostbit function, since the postbit template would have been evaluated before the $level variable was set. So I just put it above the place where the postbit template was evaluated.
![]() Is that what you were asking? If not, then just PM me and I can give a more detailed answer. ![]() BTW, I agree that the little hacks can be the most fun ![]() |
#7
|
||||
|
||||
![]()
I wasn't teasing you - i was just happy at how simple things can be
![]() - miSt |
#8
|
||||
|
||||
![]()
^_^
Thanks Bitsys That was exactly what I wanted toi know ![]() |
#9
|
||||
|
||||
![]()
^_^
Glad I was able to help ![]() |
![]() |
|
|
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
![]() |
|
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|