Passer la navigation

[Résolu] Make the CSS if select without selected option

This support ticket is created Il y a 2 years, 8 months. There's a good chance that you are reading advice that it now obsolete.

This is the technical support forum for Toolset - a suite of plugins for developing WordPress sites without writing PHP.

Everyone can read this forum, but only Toolset clients can post in it. Toolset support works 6 days per week, 19 hours per day.

Ce sujet contient 1 reply, a 2 voix.

Dernière mise à jour par Christopher Amirian Il y a 2 years, 8 months.

Assisté par: Christopher Amirian.

Auteur
Publications
#2517709
Screenshot 2022-12-17 at 10.58.14 PM.png

Dear Sir/Madam,

How can I make the CSS if a select element without selected option, I want to color it if is has no item selected.

#2518231

Christopher Amirian
Supporter

Les langues: Anglais (English )

Hi there,

The SELECT HTML element is rendered by the operating system and that is why you do not have much control over that, except if you use Javascript libraries.

Toolset does not have any built in functionality to implement such a thing. I did a search and found the result below:

https://stackoverflow.com/questions/13694271/modify-select-so-only-the-first-one-is-gray

But it is not exactly what you need.

As the fact that the Select is generated by Toolset does not have anything to do with the query I suggest that you ask this in stackoverflow website and see what answer you will get there

Thanks.