Merhabalar herkese bu sabah baya bi gzl şeyler paylaşacağım sanırımmm

hemen konuya giriyorum;

<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8" />
    <title>CSS Form Elemanlarını Kontrol Etme</title>
    <style>
       input[type=radio]:checked + label {
          color: blue;
       }
    </style>
</head>
<body>

   <form>
      <input type="radio" name="rad" value="Deger">
      <label for="rad"> Seçme Butonu</label>
   </form>
</body>
</html>

kodumuz yukarıdaki gibi

radio button elemanına sadece seçili olduğu zaman yazı rengini mavi yapmak istiyorsak

input[type=radio]:checked + label {
          color: blue;

kodunu kullanmamaız yeterli

kolay gelsinnn

120 views