This is the first time I've come across this issue. How can I get a variable where the variable determines the variable to get.
$foobar_list = '123123';
$type = 'foobar'
echo {$type}_list;
This is the first time I've come across this issue. How can I get a variable where the variable determines the variable to get.
$foobar_list = '123123';
$type = 'foobar'
echo {$type}_list;
Please refer to Dynamic variable names in PHP
As stated there, you need to access it as echo ${$type . '_list'}
Edit: fixed a typo