Go Back   vb.org Archive > vBulletin Modifications > Archive > vB.org Archives > vBulletin 3.5 > vBulletin 3.5 Add-ons
FAQ Community Calendar Today's Posts Search

Reply
 
Thread Tools
Hooks Manager v2 Details »»
Hooks Manager v2
Version: 2.0, by Zero Tolerance Zero Tolerance is offline
Developer Last Online: Nov 2023 Show Printable Version Email this Page

Version: 3.5.0 Beta 1 Rating:
Released: 06-09-2005 Last Update: 06-12-2005 Installs: 10
DB Changes Uses Plugins
Code Changes  
No support by the author.

Well as the vBulletin are request extra hook locations, i find it very hard that they would be able to forfill everyones request, because if they did the php files would mostly contain hook calls, so to ease the pain of adding you're own hooks manually, i have created this addon, to add/edit/delete your own hooks using the acp!

Features:
  • Adding A Custom Hook
    • Hook Category
    • Hook Name
    • Choose ANY PHP file in your forums directory to place the hook (including sub-fodlers)
    • Insert a line of PHP from the specified file to designate where the hook will be placed
    • Choose to locate the hook above or below the specified line of PHP
    • Will automatically modify your PHP file AND vbulletin_hooks.xml for you.
    • View file contents : Will automatically show the contents of the PHP file, so you can choose where to place the hook.
  • Modifying A Custom Hook
    • Change any details you inputted while creating the custom hook
    • Any plugins assigned to it will be moved to the edited version (if the hook name is changed)
  • Deleting A Custom Hook
    • Removes all file edits for that specific hook
    • Deletes all plugins assigned to that hook location
  • Repairing All Custom Hooks
    • Repairs all custom hooks : This is designed to keep your custom hooks intact, if you accidently overwrite any file with a custom hook or vbulletin_hooks.xml, or if you've just upgraded your vBulletin forum, the repair function will re-insert ALL custom hooks back onto your system, with no manual file modifications required.
  • Export Custom Hook Locations To Auto Installer
    • The custom hooks exporter is aimed at developers, and will automatically create an install file for people to use and run on there server, the intention is that you export custom hook locations for people to install so that your own modification runs off these hook locations. Please ensure that you notify users installing any modifications you provide with a custom hooks export installer to run the custom hooks installer first before proceeding to import any plugins!.
    • Installer Includes: Installer/Uninstaller/Repairer for all custom hook locations exported inside it.


File edits: 3 (admincp/plugin.php & includes/xml/cpnav_vbulletin.xml)
Requirements: CHMOD all php files in your forums directory (including sub folders) to 0666, and includes/xml/hooks_vbulletin.xml to 0666 (Will not function without this done!)


Enjoy

- Zero Tolerance

Show Your Support

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

Comments
  #22  
Old 06-13-2005, 12:34 AM
eXtremeTim eXtremeTim is offline
 
Join Date: Jun 2002
Location: eXtremewebtech.com
Posts: 1,201
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I can honestly say that what me and zt have been talking about sounds amazing. I know all my hacks will use this system to avoid file edits.
Reply With Quote
  #23  
Old 06-13-2005, 12:42 AM
Dream's Avatar
Dream Dream is offline
 
Join Date: Oct 2001
Posts: 2,251
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

this is creepy, but ill test it out, running a test forum anyway
Reply With Quote
  #24  
Old 06-13-2005, 02:39 AM
eXtremeTim eXtremeTim is offline
 
Join Date: Jun 2002
Location: eXtremewebtech.com
Posts: 1,201
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

wait till you see the next version.
Reply With Quote
  #25  
Old 06-13-2005, 04:54 AM
Zero Tolerance's Avatar
Zero Tolerance Zero Tolerance is offline
 
Join Date: Feb 2004
Location: England
Posts: 813
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

v2 released, this is what eXtremeTim gave me the idea about and was excited about

Quote:
The custom hooks exporter is aimed at developers, and will automatically create an install file for people to use and run on there server, the intention is that you export custom hook locations for people to install so that your own modification runs off these hook locations. Please ensure that you notify users installing any modifications you provide with a custom hooks export installer to run the custom hooks installer first before proceeding to import any plugins!.
Enjoy

- Zero Tolerance
Reply With Quote
  #26  
Old 06-14-2005, 03:49 PM
eXtremeTim eXtremeTim is offline
 
Join Date: Jun 2002
Location: eXtremewebtech.com
Posts: 1,201
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I can tell you this so far this hack looks great.
Reply With Quote
  #27  
Old 06-17-2005, 09:44 AM
Frenck's Avatar
Frenck Frenck is offline
 
Join Date: Dec 2001
Location: Hengelo, The Netherlands
Posts: 31
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

The button 'Show File Contents' seems not to work in firefox.


A second one.... I want to add a hook in includes/class_bbcode.php

PHP Code:
        function handle_bbcode_code($code)
        {

                
//  THIS IS THE PLACE WHERE I WANT A HOOK....


                
global $vbulletin$vbphrase$stylevar$show;

                
// remove unnecessary line breaks and escaped quotes
                
$code str_replace(array('<br>''<br />''\\"'), array('''''"'), $code);

                
$code $this->strip_front_back_whitespace($code1);

                
// fetch height of block element
                
$blockheight $this->fetch_block_height($code);

                
$template $this->printthread 'bbcode_code_printthread' 'bbcode_code';
                eval(
'$html = "' fetch_template($template) . '";');
                return 
$html;
        } 
How to create one with your plugin? I can't specify only '{' as the line to add the hook below, how to do this nicely?

May you have to expand your option to put a hook not online above or below a specified php line, but maybe also 2, 3, 4, 5 lines above or below...
Reply With Quote
  #28  
Old 06-17-2005, 03:13 PM
FASherman's Avatar
FASherman FASherman is offline
 
Join Date: Aug 2002
Posts: 289
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

After some long thought on this, I'd like to make a proposal to all the entire vb.com community to make allour lives easier.

1. Only hacks that require changes to sql queries should be hacks.

2. Take THIS hack and place it in a seperate forum calls "Add-on Hooks". When a someone codes a hack that can't use a standard hook, they add an add-on hook into this forum. Then they can release their hack as a plug-in. One the add-on hook is released, it can be used by anyone. It becomes an unoffical extension of VB.

3. In the description for plugins, add an additional 2 fields:
Requires add-on hook (y/n)
ThreadID of Add-on Hook.

4. The folsk at VB.Com now have a way to see how many plugins use these add-on hooks. If we have an add-on hook that is used by 20 or more hacks, they know that it should be incorporated into the next release. As they do so, then that add-on hook can be removed from the forum and the hacks updated as full-plugin without add-on hooks.

5. For those of us with hacked boards, all it means is that we have to reinstall our hooks, not the entire hack.

Comments/questions/concerns?
Reply With Quote
  #29  
Old 06-17-2005, 10:21 PM
Ron1n Ron1n is offline
 
Join Date: Jun 2004
Posts: 373
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

i am in love - this hack is great
Reply With Quote
  #30  
Old 06-27-2005, 06:31 AM
macooper macooper is offline
 
Join Date: May 2005
Location: UK
Posts: 15
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Hi,
I'm not sure how well this would work, but when patching the linux kernel, they use something called context diffs. Could this be adapted for this mod ?

The idea is that when you add a new hook, your system would take say 10 lines of code before and 10 lines after the hook location. When an upgrade is performed, any hooks in code that has not changed would be easily detected. However, if the 10 lines above / below the code have changed, then you would know that the hook needed redoing manually.

On applying the hooks to an upgraded board, you could then generate a list of failed patches that would need to be added manually. Not perfect, I know, but it would pick up the majority of failed hooks.

Martin
Reply With Quote
  #31  
Old 08-13-2005, 12:40 PM
thermz thermz is offline
 
Join Date: Aug 2005
Posts: 1
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Wow, exceeded yourself again.
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 07:12 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.11967 seconds
  • Memory Usage 2,315KB
  • 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_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
  • (3)pagenav_pagelink
  • (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