I have a dropdown which has a value saved from the database. The problem is, when I go to the page to view the values it returns to the default. Here are my screenshots:
On my 1st image, it displays an alert message showing the subscription type's value.
Right after clicking OK in the alert box, the value of the dropdown subscription type is reset to blank. Please see 2nd image for reference :
here is a screenshot of the inspect element of the dropdown list. In the inspect element, it actually has a value selected:
When I refresh the page, the actual value then displays but in the alert message, it does not get the value. Please see 4th image for reference:
Now when I try to click submit, a validation message displays for the subscription_type dropdown list stating that it does not have a value when in fact it does. Please see 5th picture for reference :
Any thoughts? please pardon the long post due to the pictures. I need to post pics for clearer understanding of the problem. Also, I do not have any code specialized for the dropdown value so I'm wondering why it is working it like that.
If anything, here is the dropdown list's code in the .xml form:
<field name ="subscription_type" type="list"
label="Subscription Type"
description="Type of Subscription either Regular or Special"
option_on ="Yes"
option_off ="Yes"
default = ""
required="true"
>
<option value = "">- Select Subscription Type -</option>
<option value ="RDS">RDS</option>
<option value ="SDS">SDS</option>
</field>
selected="selected"
. If so, we at least know that we are tracking a javascript and not a PHP issue. Since I think that is the case, the question becomes, are you using anything different to style or add features using javascript to the form?