PDA

View Full Version : Moving Variables to another Template


GameWizard
02-21-2008, 04:10 AM
I recently asked a similar question here:
https://vborg.vbsupport.ru/showthread.php?t=170042

However this time I am moving the following variables.

$block_data[picturecount]
$block_data[albumcount]

I moved these from the memberinfo_block_statistics template into the memberinfo_block_ministats template to no avail.

Nothing shows up, even when changing the variable name to every conceivable combination I could come up with including $userinfo[picturecount], $albuminfo[picturecount], and so forth.

I hope someone can shed light on this for me.

Guest190829
02-21-2008, 06:24 AM
These variables do not have scope in the template you want to move them too. The idea of variable scope is integral to programming - the only way you are going to be able to move the variables is actually alter the PHP code with hooks/or file edits.

GameWizard
02-21-2008, 07:09 AM
Understood, could you point me in the right direction as to which files need to be changed, or how to create an appropriate plugin to achieve this?