I want to run a simple if statement on a form to generate the email content. The email even is triggered after the DB save.
for is a drop down list which has "Self" as a value & name is a text box.
The text I get is
TEST data[`for`]}<>"Self") { echo "
This booking has been made by "; echo $user->name; echo " on behalf of MyName"; } else {echo "not worked";) ?>
Sorry I know there is something obvious but gone code blind :-(
TEST
<?php
$user =& JFactory::getUser();
?>
<?php if ({$form->data['for']}<>"Self")
{
echo "<p>This booking has been made by ";
echo $user->name;
echo " on behalf of {name}";
}
else
{$echo "not worked";)
?>
for is a drop down list which has "Self" as a value & name is a text box.
The text I get is
TEST data[`for`]}<>"Self") { echo "
This booking has been made by "; echo $user->name; echo " on behalf of MyName"; } else {echo "not worked";) ?>
Sorry I know there is something obvious but gone code blind :-(