Witaj Gościu! ( Zaloguj | Rejestruj )

Forum PHP.pl

 
Reply to this topicStart new topic
> [HTML][CSS]Button z obrazkowym tłem
trifek
post 29.12.2018, 11:51:26
Post #1





Grupa: Zarejestrowani
Postów: 340
Pomógł: 0
Dołączył: 28.09.2015

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


Witam.
Mam taki kod:

  1.  
  2. .subbmitCommentBtn {
  3. background: url("../images/ikon2.png") no-repeat center top;
  4. padding-right: 15px;
  5. padding-left: 15px;
  6. color: white;
  7. cursor: pointer;
  8. height: 56px;
  9. width: 253px;
  10. background-color: #AF191F;
  11. background-position: left;
  12. background-repeat: no-repeat;
  13. font-weight: bold;
  14. border-radius: 20px;
  15. border: none;
  16. }
  17.  
  18. <input type="submit" value="Dodaj komentarz" class=" subbmitCommentBtn">


Mam problem z tłem. Obrazek nachodzi mi za bardzo na lewą stronę. Chciałbym go odsunąć o 10px od lewej krawędzi buttona.
https://ibb.co/3kf6VNm


Wie ktoś może jak to zrobić?


Go to the top of the page
+Quote Post
trueblue
post 29.12.2018, 13:07:58
Post #2





Grupa: Zarejestrowani
Postów: 6 761
Pomógł: 1822
Dołączył: 11.03.2014

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


Sprawdź czy padding nie jest gdzieś nadpisywany.

Kod
background-position: left;
background-repeat: no-repeat;

Jaki ma to sens, skoro wyżej ustalasz pozycje i powtarzanie tła? Zrób to właśnie tam.


--------------------
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: 16.04.2024 - 04:34