gemzilla
08-30-2013, 09:20 AM
I am making a CSS sprite button that instead of going to another page it shows more (like a read more/read less button). It is not working quite properly as when you hover over it the background image of the button does not change. Also in trying to fix this for some reason the footer style has gone funny. I have not touched the CSS for the footer so I do not know why it has stopped working. Below is the CSS and link to the page, the PHP is in another comment.
Link: http://kent-telephones.ismywebsite.co.uk/exchange.php (I am working with the Sign Up button)
CSS
/* CSS Document */
body {
margin-top:0;
font-family:Arial, Helvetica, sans-serif;
}
p {
text-align:justify;
}
h1 {
text-align:center;
}
a {
color:#00C;
text-decoration:none;
}
a:hover {
color:#900;
}
.centre {
text-align:center;
margin-left:auto;
margin-right:auto;
}
img a {
border:none;
}
.left {
float:left;
margin:5px;
}
.right {
float:right;
margin:5px;
}
.textright {
text-align:right;
}
.smallprint {
font-size:10px;
font-style:italic;
}
#banner {
width:1000px;
height:500px;
margin-left:auto;
margin-right:auto;
background-image:url(../Images/graphic.jpg)
}
#logo{
width:700px;
height:300px;
margin-left:auto;
margin-right:auto;
margin-top:50px;
}
#menu{
width:1000px;
height:50px;
margin-left:auto;
margin-right:auto;
margin-top:50px;
padding:0;
}
#content{
width:1000px;
height:auto;;
min-height:800px;
margin-left:auto;
margin-right:auto;
background-image:url(../Images/background.jpg);
background-repeat:no-repeat;
background-color:#FFF;
overflow:hidden;
}
#advert {
width:800px;
height:200px;
margin:50px 100px;
}
#main{
width:900px;
height:auto;
margin-left:50px;
overflow:hidden;
}
#footer{
background-image:url(../Images/footbg.jpg);
width:1000px;
height:200px;
margin-left:auto;
margin-right:auto;
}
/* Telephone exchange fonts */
.extitle {
font-family:"Arial Black", Gadget, sans-serif;
font-size:30px;
text-shadow:2px 2px 5px #00FFFF;
}
.extext {
font-weight:bold;
color:#0000FF;
font-size:20px;
text-shadow:4px 2px 5px #FFF;
}
/* Sign Up */
#signup {
width:435px;
height:auto;
float:left;
overflow:hidden;
margin-left:10px;
}
#signuptop {
height:12px;
width:435px;
background-image:url(../Images/signuptop.fw.png);
background-repeat:no-repeat;
}
#signupbottom {
height:12px;
width:435px;
background-image:url(../Images/signupbot.fw.png);
background-repeat:no-repeat;
}
#signmiddle {
width:425px;
height:auto;
background-image:url(../Images/signupmid.fw.png);
background-repeat:repeat-y;
padding-left:5px;
padding-right:5px;
overflow:hidden;
}
#signbutton {
background-image:url(../Images/signupbutton.fw.png);
width:150px;
height:70px;
margin-right:auto;
margin-left:auto;
display:block;
text-align:center;
line-height:30px;
}
#signbutton a {
width:150px;
height:70px;
}
#signbutton a:hover {
background-image:url(../Images/signupbuttonover.fw.png;
width:150px;
height:70px;
}
/*#signbutton span {
display:none;
}*/
#signform {
width:425px;
height:auto;
overflow:hidden;
}
/* About */
#promo {
margin:10px;
}
#promo iframe {
width:420px;
height:315px;
}
/* Shop*/
#shop {
width:900px;
height:700px;
margin-left:auto;
margin-right:auto;
}
#shop iframe {
width:900px;
height:700px;
}
/* Footer */
#quickbar {
height:180px;
width:290px;
margin-left:10px;
margin-top:10px;
float:left;
}
#services {
height:180px;
width:290px;
margin-left:10px;
margin-top:10px;
float:left;
}
#quickbar ul, #services ul {
margin:0;
padding:0;
height: 180px;
width:290px;
}
#quickbar ul li, #services ul li {
margin:0;
padding:0;
list-style-type:none;
display:inline;
height:30px;
width:290px;
float:left;
line-height:30px;
}
#quickbar ul li a, #services ul li a {
display:block;
height:30px;
cursor:pointer;
font-family:Arial, Helvetica, sans-serif;
font-size:16px;
text-decoration:none;
color:#009;
}
#quickbar ul li a:hover, #services ul li a:hover, #address a:hover {
color:#900;
text-decoration:underline;
}
#contact {
height:180px;
width:auto;
margin-left:10px;
margin-top:10px;
float:right;
}
#address a {
cursor:pointer;
font-family:Arial, Helvetica, sans-serif;
font-size:16px;
text-decoration:none;
color:#009;
}
/* Contact Page */
#contactdetails {
width:360px;
height:auto;
float:left;
margin:10px;
font-size:20px;
color:#00C;
}
#contactdetails strong {
font-size:16px;
font-weight:bold;
color:#000;
}
#map {
height:auto;
width:498px;
margin:10px;
float:right;
border: 1px solid #aaa;
}
#map p {
text-align:center;
}
#map a {
font-family:"Arial Black", Gadget, sans-serif;
text-decoration:none;
color:#000;
}
#map a:hover {
color:#00C;
}
#map iframe {
width:498px;
height:500px;
}
/*Form*/
#contactform {
width:360px;
height:auto;
float:left;
margin:10px;
overflow:hidden;
}
#contactform p {
text-align:left;
}
#formdetails {
height:auto;
overflow:hidden;
}
#formdetails input {
border: 1px solid #aaa;
width:200px;
float:right;
margin-right:50px;
margin-top:3px;
}
#formdetails label {
float:left;
margin-top:3px;
}
#formdetails3 {
width:180px;
float:left;
height:auto;
overflow:hidden;
}
#formhide {
width:180px;
float:left;
height:auto;
overflow:hidden;
}
#formdetails3 option[value='other'] {
}
#formmessage {
margin-top:10px;
width:360px;
overflow:hidden;
}
#formmessage textarea{
width:250px;
height:100px;
}
/* Messages */
.error {
margin: 15px 0;
padding: 10px 0 10px 15px;
border-radius: 5px;
-moz-border-radius: 5px;
-webkit-border-radius: 5px;
-o-border-radius: 5px;
border: 1px solid #961f19;
box-shadow: inset 0 1px 1px #ed8d88, 0 1px 3px rgba(0, 0, 0, 0.4);
color: #ffffff;
text-shadow: 0 -1px 0 rgba(0, 0, 0, 0.25);
background-color: #da4f49;
*background-color: #bd362f;
background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#ee5f5b), to(#bd362f));
background-image: -webkit-linear-gradient(top, #ee5f5b, #bd362f);
background-image: -o-linear-gradient(top, #ee5f5b, #bd362f);
background-image: linear-gradient(to bottom, #ee5f5b, #bd362f);
background-image: -moz-linear-gradient(top, #ee5f5b, #bd362f);
background-repeat: repeat-x;
border-color: #bd362f #bd362f #802420;
border-color: rgba(0, 0, 0, 0.1) rgba(0, 0, 0, 0.1) rgba(0, 0, 0, 0.25);
filter: progid:dximagetransform.microsoft.gradient(startColorstr='#ffee5f5b', endColorstr='#ffbd362f', GradientType=0);
filter: progid:dximagetransform.microsoft.gradient(enabled=false);
}
.error ul {
list-style: none;
padding: 0;
margin: 0;
}
.error ul li {
margin: 5px 0;
}
.success {
padding: 10px 0 10px 15px;
border-radius: 5px;
-moz-border-radius: 5px;
-webkit-border-radius: 5px;
-o-border-radius: 5px;
border: 1px solid #10272e;
box-shadow: inset 0 1px 1px #5f98b0, 0 1px 3px rgba(0, 0, 0, 0.4);
color: #ffffff;
text-shadow: 0 -1px 0 rgba(0, 0, 0, 0.25);
background-color: #da4f49;
*background-color: #1e3d47;
background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#266078), to(#1e3d47));
background-image: -webkit-linear-gradient(top, #266078, #1e3d47);
background-image: -o-linear-gradient(top, #266078, #1e3d47);
background-image: linear-gradient(to bottom, #266078, #1e3d47);
background-image: -moz-linear-gradient(top, #266078, #1e3d47);
background-repeat: repeat-x;
}
.success p {
margin: 0;
Kind Regards
Link: http://kent-telephones.ismywebsite.co.uk/exchange.php (I am working with the Sign Up button)
CSS
/* CSS Document */
body {
margin-top:0;
font-family:Arial, Helvetica, sans-serif;
}
p {
text-align:justify;
}
h1 {
text-align:center;
}
a {
color:#00C;
text-decoration:none;
}
a:hover {
color:#900;
}
.centre {
text-align:center;
margin-left:auto;
margin-right:auto;
}
img a {
border:none;
}
.left {
float:left;
margin:5px;
}
.right {
float:right;
margin:5px;
}
.textright {
text-align:right;
}
.smallprint {
font-size:10px;
font-style:italic;
}
#banner {
width:1000px;
height:500px;
margin-left:auto;
margin-right:auto;
background-image:url(../Images/graphic.jpg)
}
#logo{
width:700px;
height:300px;
margin-left:auto;
margin-right:auto;
margin-top:50px;
}
#menu{
width:1000px;
height:50px;
margin-left:auto;
margin-right:auto;
margin-top:50px;
padding:0;
}
#content{
width:1000px;
height:auto;;
min-height:800px;
margin-left:auto;
margin-right:auto;
background-image:url(../Images/background.jpg);
background-repeat:no-repeat;
background-color:#FFF;
overflow:hidden;
}
#advert {
width:800px;
height:200px;
margin:50px 100px;
}
#main{
width:900px;
height:auto;
margin-left:50px;
overflow:hidden;
}
#footer{
background-image:url(../Images/footbg.jpg);
width:1000px;
height:200px;
margin-left:auto;
margin-right:auto;
}
/* Telephone exchange fonts */
.extitle {
font-family:"Arial Black", Gadget, sans-serif;
font-size:30px;
text-shadow:2px 2px 5px #00FFFF;
}
.extext {
font-weight:bold;
color:#0000FF;
font-size:20px;
text-shadow:4px 2px 5px #FFF;
}
/* Sign Up */
#signup {
width:435px;
height:auto;
float:left;
overflow:hidden;
margin-left:10px;
}
#signuptop {
height:12px;
width:435px;
background-image:url(../Images/signuptop.fw.png);
background-repeat:no-repeat;
}
#signupbottom {
height:12px;
width:435px;
background-image:url(../Images/signupbot.fw.png);
background-repeat:no-repeat;
}
#signmiddle {
width:425px;
height:auto;
background-image:url(../Images/signupmid.fw.png);
background-repeat:repeat-y;
padding-left:5px;
padding-right:5px;
overflow:hidden;
}
#signbutton {
background-image:url(../Images/signupbutton.fw.png);
width:150px;
height:70px;
margin-right:auto;
margin-left:auto;
display:block;
text-align:center;
line-height:30px;
}
#signbutton a {
width:150px;
height:70px;
}
#signbutton a:hover {
background-image:url(../Images/signupbuttonover.fw.png;
width:150px;
height:70px;
}
/*#signbutton span {
display:none;
}*/
#signform {
width:425px;
height:auto;
overflow:hidden;
}
/* About */
#promo {
margin:10px;
}
#promo iframe {
width:420px;
height:315px;
}
/* Shop*/
#shop {
width:900px;
height:700px;
margin-left:auto;
margin-right:auto;
}
#shop iframe {
width:900px;
height:700px;
}
/* Footer */
#quickbar {
height:180px;
width:290px;
margin-left:10px;
margin-top:10px;
float:left;
}
#services {
height:180px;
width:290px;
margin-left:10px;
margin-top:10px;
float:left;
}
#quickbar ul, #services ul {
margin:0;
padding:0;
height: 180px;
width:290px;
}
#quickbar ul li, #services ul li {
margin:0;
padding:0;
list-style-type:none;
display:inline;
height:30px;
width:290px;
float:left;
line-height:30px;
}
#quickbar ul li a, #services ul li a {
display:block;
height:30px;
cursor:pointer;
font-family:Arial, Helvetica, sans-serif;
font-size:16px;
text-decoration:none;
color:#009;
}
#quickbar ul li a:hover, #services ul li a:hover, #address a:hover {
color:#900;
text-decoration:underline;
}
#contact {
height:180px;
width:auto;
margin-left:10px;
margin-top:10px;
float:right;
}
#address a {
cursor:pointer;
font-family:Arial, Helvetica, sans-serif;
font-size:16px;
text-decoration:none;
color:#009;
}
/* Contact Page */
#contactdetails {
width:360px;
height:auto;
float:left;
margin:10px;
font-size:20px;
color:#00C;
}
#contactdetails strong {
font-size:16px;
font-weight:bold;
color:#000;
}
#map {
height:auto;
width:498px;
margin:10px;
float:right;
border: 1px solid #aaa;
}
#map p {
text-align:center;
}
#map a {
font-family:"Arial Black", Gadget, sans-serif;
text-decoration:none;
color:#000;
}
#map a:hover {
color:#00C;
}
#map iframe {
width:498px;
height:500px;
}
/*Form*/
#contactform {
width:360px;
height:auto;
float:left;
margin:10px;
overflow:hidden;
}
#contactform p {
text-align:left;
}
#formdetails {
height:auto;
overflow:hidden;
}
#formdetails input {
border: 1px solid #aaa;
width:200px;
float:right;
margin-right:50px;
margin-top:3px;
}
#formdetails label {
float:left;
margin-top:3px;
}
#formdetails3 {
width:180px;
float:left;
height:auto;
overflow:hidden;
}
#formhide {
width:180px;
float:left;
height:auto;
overflow:hidden;
}
#formdetails3 option[value='other'] {
}
#formmessage {
margin-top:10px;
width:360px;
overflow:hidden;
}
#formmessage textarea{
width:250px;
height:100px;
}
/* Messages */
.error {
margin: 15px 0;
padding: 10px 0 10px 15px;
border-radius: 5px;
-moz-border-radius: 5px;
-webkit-border-radius: 5px;
-o-border-radius: 5px;
border: 1px solid #961f19;
box-shadow: inset 0 1px 1px #ed8d88, 0 1px 3px rgba(0, 0, 0, 0.4);
color: #ffffff;
text-shadow: 0 -1px 0 rgba(0, 0, 0, 0.25);
background-color: #da4f49;
*background-color: #bd362f;
background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#ee5f5b), to(#bd362f));
background-image: -webkit-linear-gradient(top, #ee5f5b, #bd362f);
background-image: -o-linear-gradient(top, #ee5f5b, #bd362f);
background-image: linear-gradient(to bottom, #ee5f5b, #bd362f);
background-image: -moz-linear-gradient(top, #ee5f5b, #bd362f);
background-repeat: repeat-x;
border-color: #bd362f #bd362f #802420;
border-color: rgba(0, 0, 0, 0.1) rgba(0, 0, 0, 0.1) rgba(0, 0, 0, 0.25);
filter: progid:dximagetransform.microsoft.gradient(startColorstr='#ffee5f5b', endColorstr='#ffbd362f', GradientType=0);
filter: progid:dximagetransform.microsoft.gradient(enabled=false);
}
.error ul {
list-style: none;
padding: 0;
margin: 0;
}
.error ul li {
margin: 5px 0;
}
.success {
padding: 10px 0 10px 15px;
border-radius: 5px;
-moz-border-radius: 5px;
-webkit-border-radius: 5px;
-o-border-radius: 5px;
border: 1px solid #10272e;
box-shadow: inset 0 1px 1px #5f98b0, 0 1px 3px rgba(0, 0, 0, 0.4);
color: #ffffff;
text-shadow: 0 -1px 0 rgba(0, 0, 0, 0.25);
background-color: #da4f49;
*background-color: #1e3d47;
background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#266078), to(#1e3d47));
background-image: -webkit-linear-gradient(top, #266078, #1e3d47);
background-image: -o-linear-gradient(top, #266078, #1e3d47);
background-image: linear-gradient(to bottom, #266078, #1e3d47);
background-image: -moz-linear-gradient(top, #266078, #1e3d47);
background-repeat: repeat-x;
}
.success p {
margin: 0;
Kind Regards