I'm having difficulty assigning a PHP variable to a HTML form data.
I have assigned other text fields as variable but when I mimic this in a function it's just not playing ball...
My HTML code (only basic to start off) is:
<select id="userbrand">
<option> Option1</option>
<option> Option2</option>
<option> Option3</option>
and the corresponding PHP code is:
$camp_name = $_POST['campName'];
$broad_date = $_POST['broadDate'];
$userdomain = $_POST['userbrand'];
campName and broadDate contain the POST data from some text fields before the dropdown.
When submitting the form, I receive the following error:
Notice: Undefined index: userbrand in C:\wamp64\www\action_page.php on line 19
Is this an issue with my PHP code or my HTML?
Many Thanks in Advance