Page 1 of 1

$_POST[first_name] in variable not showing up

Posted: Thu Oct 23, 2008 7:18 pm
by ringartdesign
I've got this variable that uses based on user input, uses POST to output their name:

if (($_POST['age'] >= 18) && ($_POST['age'] <= 64))
$maincopy = '<p><CENTER>Thank you <b>$_POST[first_name]</b> for requesting a quote.<br />
Your are eligible for heatlh insurance rates as low as:<br />';

but when the page is published what I get is this text on the front end:

Thank you $_POST[first_name] for requesting a quote.
Your are eligible for heatlh insurance rates as low as:

I bet my syntax is wrong somewhere, but for some reason, I'm overlooking it. Any help?

Re: $_POST[first_name] in variable not showing up

Posted: Thu Oct 23, 2008 7:30 pm
by mini4
try like this:
$maincopy = "<p><CENTER>Thank you <b>".$_POST['first_name']."</b> for requesting a quote.<br />
Your are eligible for heatlh insurance rates as low as:<br />";

Re: $_POST[first_name] in variable not showing up

Posted: Thu Oct 23, 2008 7:34 pm
by ringartdesign
thank you this worked!

problem solved :)