vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vBulletin 4.x Add-ons (https://vborg.vbsupport.ru/forumdisplay.php?f=245)
-   -   Administrative and Maintenance Tools - Search for and Find Functions and Hooks in Admin CP (vB3, vB4) (https://vborg.vbsupport.ru/showthread.php?t=288519)

nerbert 09-30-2012 10:00 PM

Search for and Find Functions and Hooks in Admin CP (vB3, vB4)
 
1 Attachment(s)
Notice:

If you uploaded the original version of this product you will have to replace function_finder.php. The version you have is a very old one from when I was developing this. Lots of styling and phrase problems and it won't find all the functions. Upload the new version and click the link at the bottom of the File Finder page to rebuild the function list.

Sorry for the mistake!


General:

Before I began making modifications for vBulletin I read through all the files and memorized all the functions and hooks, their names and locations. It was a rather tedious evening but well worth it in the long run. I know most of you aren't as organized and dedicated as I am, so I built you a product for locating functions and hooks, I hope you appreciate it; it took me over an hour to build!


How it works:

The first time you open either the Function Finder or the Hook Finder in the Plugin & Products group the product reads through all the files using regular expressions to locate functions and hooks, When one is found it records the file and line number along with the name and concatenates it into a string which is stored in filelist.php or hooklist.php, which it creates in the includes folder. When you type in a function name, partial or complete, it uses regular expressions to locate the function (or hook) in the created files. You can search functions by function name or file name or both. Wildcard searches can also be done. Similarly you can search for hooks by file name or use the select menu (just like in the New Plugin page) to locate them. Once you click on the link of matches the entire file is displayed in a new window with the appropriate lines marked and the file scrolled into position. If you've changed any of the files, added files or upgraded you can rebuild filelist.php and hooklist.php with the links at the bottom of the pages. The pictures tell it all.


Installation:

I didn't zip the files so all you have to do is upload them directly to the appropriate folders. function_finder.php goes in forum/admincp and cpnav_function_finder.xml goes in forum/includes/xml. Then upload the product file in Products.

Let me know if you have any problems.

nerbert 10-01-2012 03:59 AM

Oops, I forgot to upload the product file. Now it's there. (It's been a long day!)

Rich 10-01-2012 10:02 PM

Quote:

I know most of you aren't as organized and dedicated as I am, so I built you a product for locating functions and hooks, I hope you appreciate it; it took me over an hour to build!
The mod is a nice addition but your ego and arrogant attitude leave much to be desired.

nerbert 10-01-2012 10:36 PM

Oh c'mon, where's your sense of humor?

Snowhog 10-01-2012 11:28 PM

He's Bart S. Did you expect anything less? :)

qpurser 10-02-2012 05:42 AM

Thank you.
Don't let stupid comments discourage from writing helpful mods to make our life easier.
And YES I am one of those who is not as organized as he should be.

I will test it on my test server and give feedback.

Thanks
Michael

qpurser 10-02-2012 06:30 AM

ok. Just installed it.
Uploaded the 2 files in the appropriate folders.
Imported the product.

Both links show up in my adminCP but there is something wrong I guess.
No matter if I click on "Hook Finder" or "Function Finder" both go the same page "Search for functions". The "Search for Hooks" doesn't show up.

I noticed when I hover over the options in the adminCP each show something different.
Links are showing like: "function_finder.php?do=functions" and "function_finder.php?do=hooks"
but as mentioned they both go to the "search function" page

nerbert 10-02-2012 09:33 AM

I just uploaded an improved version of function_finder.php. I tidied up some styling problems and worked out some compatibility problems with IE. The scrolling to position in the file display should work better now.

Quote:

Originally Posted by qpurser (Post 2370142)
ok. Just installed it.
Uploaded the 2 files in the appropriate folders.
Imported the product.

Both links show up in my adminCP but there is something wrong I guess.
No matter if I click on "Hook Finder" or "Function Finder" both go the same page "Search for functions". The "Search for Hooks" doesn't show up.

I noticed when I hover over the options in the adminCP each show something different.
Links are showing like: "function_finder.php?do=functions" and "function_finder.php?do=hooks"
but as mentioned they both go to the "search function" page

That's strange. Maybe it will work with the new file. Everything's working for me and I uploaded the files straight off the server.

qpurser 10-02-2012 09:43 AM

Quote:

Originally Posted by nerbert (Post 2370157)
I just uploaded an improved version of function_finder.php. I tidied up some styling problems and worked out some compatibility problems with IE. The scrolling to position in the file display should work better now.

That's strange. Maybe it will work with the new file. Everything's working for me and I uploaded the files straight off the server.

I replaced the function_finder.php with the new one and now it works perfect.
Also I noticed the improvement with the styling

Thanks

nerbert 10-02-2012 10:17 AM

Quote:

Originally Posted by qpurser (Post 2370159)
I replaced the function_finder.php with the new one and now it works perfect.
Also I noticed the improvement with the styling

Thanks

This is a real mystery why the old file didn't work. My theory is that what I had uploaded was a very early version of the file from way back. I don't know how many times I've accidentally downloaded files when I click on a file link in cPanel. Would you test something for me? Try searching for "print_cp_footer" and see if you have any matches. If it's the old junker file it won't find it because a regular expression was not quite right. If you don't find it you will have to rebuild filelist.php with the link at the bottom of the page.


All times are GMT. The time now is 01:14 PM.

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.05203 seconds
  • Memory Usage 1,746KB
  • Queries Executed 10 (?)
More Information
Template Usage:
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (4)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (2)pagenav_pagelink
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (10)printthreadbit
  • (1)spacer_close
  • (1)spacer_open 

Phrase Groups Available:
  • global
  • postbit
  • showthread
Included Files:
  • ./printthread.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/class_bbcode_alt.php
  • ./includes/class_bbcode.php
  • ./includes/functions_bigthree.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
  • printthread_start
  • pagenav_page
  • pagenav_complete
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete