Welcome to collectivesolver - Programming & Software Q&A. A website you can trust. All programs tested and works. Contact: aviboots(AT)netvision.net.il
Liquid Web Managed Dedicated Server: RAID 1 SSD with 16GB of RAM minimum! 24/7 On-Site Heroic Support! Industry-Leading SLA!

BlueHost Web Hosting

Ecommerce Software - Best Ecommerce Platform Made for You - Free Trial

Ecommerce Software - Best Ecommerce Platform Made for You - Free Trial

getflywheel wordpress hosting


Liquid Web Cloud VPS Hosting

8,512 questions

11,796 answers

573 users

How to change the select option HTML tag color with CSS

informit.com | the trusted technology learning source - 6,633 eBook | InformIT eBook Store


22 views
asked Dec 26, 2015 by avibootz
edited Dec 26, 2015 by avibootz

3 Answers

0 votes
<!DOCTYPE html>
<html>
    <head>
        <style type="text/css">
            select {
                color: gray;
            }
        </style>
    </head>
    <body>
        <select name="gender">
            <option value="iam">I am</option>
            <option style="color:black" value="female">Female</option>
            <option style="color:black" value="male">Male</option>
        </select>
    </body>
</html>

 




answered Dec 26, 2015 by avibootz
0 votes
<!DOCTYPE html>
<html>
    <head>
        <style type="text/css">
            select option {
                color: blue;
            }
        </style>
    </head>
    <body>
        <select name="gender">
            <option style="color:gray" value="iam">I am</option>
            <option value="female">Female</option>
            <option value="male">Male</option>
        </select>
    </body>
</html>

 




answered Dec 26, 2015 by avibootz
0 votes
<!DOCTYPE html>
<html>
    <head>
        <style type="text/css">
            select option {
                color: blue;
            }
        </style>
        
        <style type="text/css">
            .numbers option {
                color: green;
            }
        </style>
    </head>
    <body>
        <select name="gender">
            <option style="color:gray" value="iam">I am</option>
            <option value="female">Female</option>
            <option value="male">Male</option>
        </select>
        <select>
    <optgroup label="Numbers" class="numbers">
        <option style="color:gray" value="0">Zero</option>
        <option value="1">One</option>
        <option value="2">Two</option>
    </optgroup>

</select>
    </body>
</html>

 




answered Dec 27, 2015 by avibootz
...