So I am getting the classic error:
Cannot use parentheses when calling a Sub
when trying to execute this code on my webpage.
Here is the code:
<select class=<% Response.write("""" & colour & " ")%> selection" name="col" id="chosen">
<option value="none" selected disabled>---</option>
<option value="red">Red</option>
<option value="blue">Blue</option>
<option value="green">Green</option>
</select>
</div>
<br>
<input type="submit" class=<% Response.write("""" & colour & " ")%> btn" value="This one!">
</form>
<%
if chosen.value = Red then PageBody.Attributes.Add("bgcolor", "red")
elseif chosen.value = Blue then PageBody.Attributes.Add("bgcolor", "blue")
elseif chosen.value = Green then PageBody.Attributes.Add("bgcolor", "green")
end if
%>
Basically I am trying to change the background of the page depending on the option the user chooses from my HTML dropdown menu. I don't understand what I am doing wrong.