The Arcive of Official vBulletin Modifications Site.It is not a VB3 engine, just a parsed copy! |
|
#1
|
|||
|
|||
![]()
It seems (from my view) that vBulletin uses arrays in order to run things. Such as a $post array holding values like $post['username'], $post['userid']. The same is true for $user.
I was wondering, how would I go about showing these arrays on a separate page so I could see what $post, $user, $show etc. arrays hold what values. I want to learn more about vBulletin's code. |
#2
|
|||
|
|||
![]()
You can show them on the current page, but you can't on a seperate page as this page would not have all the variables loaded that are on the primary page.
|
#3
|
|||
|
|||
![]()
Is there any vBulletin page with all of them variables on it? So I can just print the array and see what each variable holds on one page rather than separate ones?
|
#4
|
|||
|
|||
![]()
No, they are dynamic.
|
#5
|
|||
|
|||
![]()
Ah. Would a simple print_r($user); work in order to show the values of an array?
If so, would I put this in the template or the file (i.e. index.php)? |
#6
|
|||
|
|||
![]()
For debugging you can use a print_r(), but you might need to end the script execution afterwards.
For debugging arrays i always use the following myself (have it assigned to a macro in my editor): PHP Code:
|
#7
|
||||
|
||||
![]()
You can also view the source of the page to get a correctly line-broken output.
|
#8
|
|||
|
|||
![]()
Thanks for the code Marco. I have tried a variety of locations (showthread.php, index.php, FORUMHOME template, POSTBIT template, SHOWTHREAD template) with this code with no luck. Would this code require it to go in the php file or the template?
Also, would I need debug mode on? |
![]() |
|
|
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
![]() |
|
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|