How do I supply a variable to put in a another variable in PHP?
- by Jared
I'm not sure if I asked the question correctly.
I have some code I am trying to embed. For instance:
$menuPopup ='<IMG SRC="' . $someVariable . '">';
Later on, I have the a few product variables:
$someProduct1 ='image1.jpg';
$someProduct2 ='image2.jpg';
Later on, want to display the $menuPopup, using a src from $someProduct1, or $someProduct2.
//Pseudo Code
$menuPopup ( $someProduct1);
Anyway to do that?