dynamic variable headache
| From: | ROBERT MCPEAK | Date: | Fri, 08 Nov 2002 17:17:32 +0000 |
| Subject: | dynamic variable headache | ||
| Groups: | php.general | ||
| Request: | Send a blank email to php-general+get-123432@lists.php.net to get a copy of this message | ||
My newbie brain is maxed out on this, and I'm sure one of you more experience guys can quickly
straighten me out.
I've got a variable:
$_yyyymmdd = a_date_value;
Later, I've got four variables;
$foo= _;
$bar=yyyy;
$bleh=mm;
$doh=dd;
I want to stick these variables together on the fly to get "_yyyymmdd " and use that value
as a variable name to return "a_date_value".
It would be the equivalent of,
echo "$foo$bar$bleh$doh";
That would give me "a_date_value"
I've read the docs on dynamic variables but still can't seem to break through mentally on
this one. Can you clear this up for me?
Thanks in advance.