I’m trying to assign an array to “$dataar” like this:
[php]$dataar[]=array($dataarstring);[/php]
The only problem is I want the “$dataarstring” to be a list of variables, specifically other arrays. I want whatever is in the “$dataarstring” to be echoed so the result is something like this:
[php]$dataar[]=array($ifdescar[$theid],$ifaliasar[$theid],$ifadminstatusar[$theid]);[/php]
The list of variables changes. Instead of having to create tons and tons of if statements for different conditions of variables, I’d like to just add a list of my array variables to “$dataarstring” then echo it inside that first line of code. Is this possible?
I’d populate “$dataarstring” like this:
[php]$dataarstring=’$ifdescar[$theid],$ifaliasar[$theid],$ifadminstatusar[$theid]’;
//Some other array needs to be added
$dataarstring=$dataarstring . ‘,$ifoperstatusar[$theid]’;[/php]
When “$dataarstring” is echoed inside the first line I can’t figure out how to get PHP to treat it like a list of variables instead of just a text string.