MyBB Community Forums

Full Version: How can I learn about MyBB $variables?
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
I have been trying to learn PHP & MySQL over the past few weeks, and have made a good start. However, when I come over to MyBB and look at the code, I can understand everything except the MyBB variables, therefore I have no idea what is going on in the code.

So my question is this: Is there a quick reference for MyBB $variables that shows us what each $variable defined in the MyBB source code does?
There is no official guide to list all variables and its use in MyBB... you can try this following method to fetch the variables... thats how i learnt...


(2011-12-09, 06:23 PM)pavemen Wrote: [ -> ]create a new php called test.php, fill it with the below content and put it in your forum root and then access the url


<?php 
define("IN_MYBB", 1);
include "global.php";
echo '<pre>';
print_r($mybb);
echo '</pre>';
?>
this will dump the entire $mybb object with all its settings, variables, etc.
You can do the same for $db, $lang, $config, $theme, etc.


You can however have a look at the various Plugin Hooks

And this external site also would be of some help...