Solved

unable to increase size of horizontal list item using css

Posted on 2008-10-02
3
327 Views
Last Modified: 2013-11-19
I'm trying to make these hover buttons side by side like in a horizontal menu but the buttons won't seem to get bigger even if I fix their height and width
.button li{
display: inline;
background-repeat: no-repeat;
}
 
.button li a{
background-color: #CCCCCC;
/*background-image: url(normal image path);*/
background-repeat: no-repeat;
width: 100px;
height: 50px;
}
 
.button li a:hover{
background: none;
}
 
 
 
 
<div align="center">
<ul class="button">
<li><a href="#test">My link</a></li>
<li><a href="#test">My link</a></li>
</ul>
</div>

Open in new window

0
Comment
Question by:MeridianManagement
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
3 Comments
 
LVL 5

Expert Comment

by:jericotolentino
ID: 22630996
I'm not really sure what you're trying to do, but you can try:

padding: 10px;

if it works for you.
0
 
LVL 2

Author Comment

by:MeridianManagement
ID: 22631041
I want to make horizontal hover buttons. Padding 10 doesn't work because it makes the LI bigger but the gray part where the links are still looks small.
0
 
LVL 1

Accepted Solution

by:
santoshrajan earned 500 total points
ID: 22631113
Set the width and height for 'li' css and remove it fro where it is now.
.button li{
display: inline;
background-repeat: no-repeat;
width: 100px;
height: 50px;
}
 

Open in new window

0

Featured Post

Enroll in June's Course of the Month

June's Course of the Month is now available! Every 10 seconds, a consumer gets hit with ransomware. Refresh your knowledge of ransomware best practices by enrolling in this month's complimentary course for Premium Members, Team Accounts, and Qualified Experts.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This article demonstrates how to create a simple responsive confirmation dialog with Ok and Cancel buttons using HTML, CSS, jQuery and Promises
Find out what you should include to make the best professional email signature for your organization.
This tutorial will teach you the core code needed to finalize the addition of a watermark to your image. The viewer will use a small PHP class to learn and create a watermark.
The viewer will learn how to create a basic form using some HTML5 and PHP for later processing. Set up your basic HTML file. Open your form tag and set the method and action attributes.: (CODE) Set up your first few inputs one for the name and …

734 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question