Question:
I can’t remove the ‘All’ selection from the dropdown menu. I’ve tried removing it from the database, but it’s not actually there. How can I get rid of it?
Product:
Wix Editor
What are you trying to achieve:
I want to remove the ‘All’ selection from the dropdown menu in my Wix site because it is not needed for my dropdown options. Despite my attempts, it still appears.
What have you already tried:
I have tried removing the ‘All’ option directly from the database where the dropdown options are stored, but it doesn’t seem to exist there. I’ve also searched through Wix forums and tutorials but haven’t found a solution.
Additional information:
This issue is affecting the user experience on my site as the ‘All’ selection is unnecessary and potentially confusing. Any guidance on how to locate and remove this option would be greatly appreciated.
this may work depending on how th edropdown and filters are set up
$w.onReady(function () {
const dropdown = $w('#yourDropdownID'); // Replace with your dropdown ID
let options = dropdown.options;
// Filter out the 'All' option
options = options.filter(option => option.label !== 'All');
// Set the filtered options back to the dropdown
dropdown.options = options;
});
1 Like
Everything @Dan_Suhr said 
If it’s connected to a dataset, you’d probably want to wrap it in a dataset onReady
as so:
$w.onReady(function () {
$w("#dataset1").onReady(() => {
const dropdown = $w('#yourDropdownID'); // Replace with your dropdown ID
let options = dropdown.options;
// Filter out the 'All' option
options = options.filter(option => option.label !== 'All');
// Set the filtered options back to the dropdown
dropdown.options = options;
})
});
As Dan mentioned, it depends on how it’s set up, but it is worth checking it thoroughly. I know people in the community would recommend a complete dataset solution, or a complete code solution, but wouldn’t mix the 2 (although it works sometimes, it’s mainly about being able to follow the setup the most efficiently)
1 Like