button ve a elementlerinde problem


/ Published in: CSS
Save to your folder(s)



Copy this code and paste it in your HTML
  1. .customButton { padding-left:8px; display:block; cursor:pointer; background:url(../media/buttons/customButtons.png) no-repeat transparent left 0; height:25px; margin-bottom:10px; float:right; }
  2. .customButton span.buttons { background:url("../media/buttons/customButtons.png") no-repeat scroll right -25px transparent; display:block; text-align:center; font-size:12px; font-weight:bold; color:#797979; height:25px; margin-left:3px; padding:3px 11px 0 18px; text-shadow:0 1px 0 #fff }
  3. .customButton span.function { position:absolute; background:url("../media/icons/buttonFunctions.png") no-repeat scroll transparent; display:block; width:18px; height:20px; }
  4. .customButton span.function.back { background-position:left 1px; }
  5. .customButton span.function.fans { background-position:left -18px; }
  6. .customButton span.function.comments { background-position:left -38px; }
  7. .customButton span.function.send { background-position:left -58px; }
  8.  
  9.  
  10. form içindeyken button kullanırken form dışında tüm bu elemanları a üzerine inşa ederiz ve a üzerine inşa ettiğimizde float kullanmazsak %100 genişlik alır bu yüzden float kullanarak tam olarak oturturuz.

Report this snippet


Comments

RSS Icon Subscribe to comments

You need to login to post a comment.