Hi,
Would appreciate an assist on this one...
A ternary operator fails, picking up a form variable, Why?
if (isset($_POST['prod_type_button']) || isset($_POST['prod_type_button2']))
{
$testprod = $_POST['productname'];
// Works...
$prod_name = (isset($_POST['productname'])) ? strip_tags(mysql_real_escape_string(trim($_POST['productname']))) : FALSE;
// Doesn't... - comes up empty.
}
Why?
And also: When I echo out a variable containing a usersubmitted text string from a textfield between two "textfield" tags (if the form submission fails elsewhere) two "" show up, surrounding the string. Is there an easy way to prevent that?