Log in

View Full Version : Complete list of functions?


Sykoi
06-18-2005, 04:35 PM
Is there a complete list of vBulletin's functions, with a brief overview of how to use them anywhere (Outside looking through the thousands of lines of code)?

I can't seem to find anything, and I really need to (Soon), so I can convert my board's older hacks to 3.5.

Thanks if anyone can help, vBulletin is great minus its support for new forum hackers (Then again, I have yet to find one forum that lists all of its functions in an easy-to-find area)

Xenon
06-20-2005, 09:30 AM
well, actually i don't have a list here, but it's not that hard.

just write a little php script which includes EVERY functions_ file of vb, and then use the php function get_defined_functions(), which will return an array containing all the functions defined :)

Sykoi
06-20-2005, 12:46 PM
Thanks, but theres still two more problems that can't be solved with a simple function :(

1. Listing the variables used in vBulletin (get_defined_vars returns an insanely long number of already-defined variables which is a VERY long list (Since a lot of usernames and forum descriptions are defined there))
2. Getting the list of arguments (func_get_args can only be used inside the function itself)

Thanks for pointing out that function for me, I wrote a simple little script to show all of the functions:

<?php
require_once('./global.php');
if ($handle = opendir('./includes')) {
while (false !== ($file = readdir($handle))) {
if ($file != "." && $file != ".." && $file != "cron" && $file != "index.html") {
require_once('./includes/'.$file);
}
}
}
$functions = get_defined_functions();
for ($i = 0; $i <= count($functions['user']); $i++) {
print $functions['user'][$i];
print "<br>";
}
?>



If I can get a complete list of functions, variables, and arguments I may write a reference manual for myself and put it online somewhere... I'm sure many more hacks would pop up if there was proper documentation ;)


Update: Fixed the script so it includes all files in ./includes/

Xenon
06-20-2005, 03:11 PM
with vb3.5. phpdoc is used, which should make such things easier in the future :)

Sykoi
06-20-2005, 03:15 PM
with vb3.5. phpdoc is used, which should make such things easier in the future :)
Is there a phpdoc readily available right now?
What about one for 3.0.7? I don't really want to update til its out of beta :P

Xenon
06-20-2005, 03:18 PM
nope 30x doesn't make use of phpdoc

35x does already, but as you said, it is still a beta and everything can still change