Witaj Gościu! ( Zaloguj | Rejestruj )

Forum PHP.pl

 
Reply to this topicStart new topic
> Problem z input:hover w CSS
Landon
post 31.05.2008, 19:05:53
Post #1





Grupa: Zarejestrowani
Postów: 83
Pomógł: 3
Dołączył: 21.04.2007
Skąd: Sosnowiec

Ostrzeżenie: (0%)
-----


Miałem taki CSS
  1. input {
  2. background-image: url(../images/form/normal.png);
  3. width: 57px;
  4. height: 14px;
  5. }
  6.  
  7. input:hover {
  8. background-image: url(../images/form/normal_hover.png);
  9. }


Lecz zaczołem potrzebować wykorzystać class w inputach no i pojawił się błąd:
gdy najadę na <input class="long"> powinno zmienić tło inputa na ../images/form/small_hover.png. Plik na pewno istnieje i jest grafiką tongue.gif Może ktos wie jak to zrobić ba do tego js nie mam ochoty stosować.

obecny css
  1. input {
  2. background-image: url(../images/form/normal.png);
  3. width: 57px;
  4. height: 14px;
  5. }
  6.  
  7. input:hover {
  8. background-image: url(../images/form/normal_hover.png);
  9. }
  10.  
  11. input.long {
  12. background-image: url(../images/form/long.png);
  13. width: 96px;
  14. }
  15.  
  16. input.long:hover {
  17. background-image: url(../images/form/small_hover.png);
  18. }
  19.  
  20. input.smal {
  21. background-image: url(../images/form/small.png);
  22. width: 41px;
  23. }
  24.  
  25. input.smal:hover {
  26. background-image: url(../images/form/small_hover.png);
  27. }


Lecz niestety nie działa

(jest to tylko fragmęt odpowiedzialny za inputy)

Ten post edytował Landon 31.05.2008, 19:06:32


--------------------
Go to the top of the page
+Quote Post
koderrr
post 31.05.2008, 20:08:50
Post #2





Grupa: Zarejestrowani
Postów: 255
Pomógł: 16
Dołączył: 4.07.2007

Ostrzeżenie: (0%)
-----


w ie nie dziala efekt hover dla niczego innego niz a
Go to the top of the page
+Quote Post
devnul
post 31.05.2008, 23:14:07
Post #3





Grupa: Zarejestrowani
Postów: 1 470
Pomógł: 75
Dołączył: 21.09.2005
Skąd: że znowu

Ostrzeżenie: (0%)
-----


jeśli problemem nie jest wspomniane IE to może spróbuj dać !important przy stylach inputów z nadanymi klasami


--------------------
Profesjonaliści są przewidywalni...
strzeż się amatorów...
FL4SHB4CK - imprezy, galerie, lokale
Go to the top of the page
+Quote Post
pitbull82
post 1.06.2008, 10:06:32
Post #4





Grupa: Zarejestrowani
Postów: 167
Pomógł: 0
Dołączył: 30.04.2004
Skąd: Częstochowa

Ostrzeżenie: (0%)
-----


Dla IE trzeba dorzucić trochę JS: http://htmldog.com/articles/suckerfish/hover/


--------------------
Go to the top of the page
+Quote Post
Landon
post 7.06.2008, 09:27:09
Post #5





Grupa: Zarejestrowani
Postów: 83
Pomógł: 3
Dołączył: 21.04.2007
Skąd: Sosnowiec

Ostrzeżenie: (0%)
-----


poradziłem sobie. no i w ie 7 łazi ładnie tongue.gif


--------------------
Go to the top of the page
+Quote Post

Reply to this topicStart new topic
1 Użytkowników czyta ten temat (1 Gości i 0 Anonimowych użytkowników)
0 Zarejestrowanych:

 



RSS Wersja Lo-Fi Aktualny czas: 8.07.2025 - 06:55