This topic is locked
[SOLVED]

 remove the "please select" in dropdown list

10/4/2018 12:28:23 PM
PHPRunner General questions
K
kouba author

i want to remove the "please select" from the drop down list when in "edit as" I select "lookup wizard". I tried to have default value set to avoid the "please select" unsuccessfully. I am using PHP 9.8 build.

Thank for any advice,

admin 10/5/2018

You can can do so adding the following Javascript code to Add/Edit pages Javascript OnLoad event.
Remove "Please select" from all dropdowns on the page:

$("select option[value='']").remove();


Remove "Please select" from a single dropdown based on field named EmployeeID:

$("select[id^='value_EmployeeID'] option[value='']").remove();
E
edgarv 10/9/2018

this works really well

$("select[id^='value_PRESSNUM'] option[value='']").refresh();


but if you have Autofill in other fields it does not complete the Autofill, any way to accomplish this?

K
kouba author 10/9/2018

Thank you all for the reply. Yes I have some autofill, so I just use the individual remove script.

E
edgarv 10/9/2018



Thank you all for the reply. Yes I have some autofill, so I just use the individual remove script.


correct, but when the page loads, if you use the remove to take the "please select", the autofill does not work, any way to make the autofill work?