I am trying to create a menu at the top of my webpage. I have four buttons I am attempting to connect together at the top of the webspage to make a menu. I am using
float: center;
They are centered but there are small gaps between my buttons. Here is a snippet of my code:
HTML:
<div align="center">
<a href="index.html">
<button align="right" type="button" class="menu1"><span>1. Things you need</span></button>
</a>
<a href="setup.html">
<button align="right" type="button" class="menu2"><span>2. Setting up your website folders</span></button>
</a>
<a href="extrainfo.html">
<button align="right" type="button" class="menu3"><span>3. Extra Information</span></button>
</a>
<a href="layout.html">
<button align="right" type="button" class="menu4"><span>4. HTML Layout</span></button>
</a>
</div>
CSS:
.menu1 {
border-radius: 10px 0px 0px 10px;
padding: 10px 25px;
background-color: #00FF00;
text-align: center;
border: 1px solid #FFFF00;
width: auto;
height: auto;
float: center;
font-weight: bold;
font-family: "Arial Black", Gadget, sans-serif;
}
.menu2 {
padding: 10px 25px;
background-color: #00FF00;
text-align: center;
border: 1px solid #FFFF00;
width: auto;
height: auto;
float: center;
font-weight: bold;
font-family: "Arial Black", Gadget, sans-serif;
}
.menu3 {
padding: 10px 25px;
background-color: #00FF00;
text-align: center;
border: 1px solid #FFFF00;
width: auto;
height: auto;
float: center;
font-weight: bold;
font-family: "Arial Black", Gadget, sans-serif;
}
.menu4 {
border-radius: 0px 10px 10px 0px;
background-color: #00FF00;
padding: 10px 25px;
text-align: center;
border: 1px solid #FFFF00;
width: auto;
height: auto;
float: center;
font-weight: bold;
font-family: "Arial Black", Gadget, sans-serif;
}
I'm sure there is a simple way around this, but I just can't get my head around it.
Thanks in advance!