Hi everyone,
I have a string that is a collection of variables without the $. This is what I have so far but they won't evaluate as variables... Thanks for the help in advanced!
$line="articles,subject,exptime";
$pieces = explode(",", $line);
foreach($pieces as $pieces2)
{
echo "$pieces2<BR>";
}
$values="'$" . implode("','$", $pieces) . "'"; // formats the array containing the form elements for db insertion
echo $values; // Output: '$articles','$subject','$exptime'