Jump to content


Photo

Problem setting height in IE and button border


  • Please log in to reply
11 replies to this topic

#1 aaron118

aaron118
  • Members
  • PipPipPip
  • Advanced Member
  • 30 posts

Posted 19 June 2006 - 09:22 PM

I am having a problem with IE, I just can't figure out how to fix it. In firefox it [a href=\"http://img132.imageshack.us/img132/7467/firefoxprob1nw.gif\" target=\"_blank\"]looks ok[/a] apart from the fact the button won't go bellow the table (even though there are <br />) but in IE there are two problems [a href=\"http://img159.imageshack.us/img159/7830/ieproblem3ul.gif\" target=\"_blank\"]as you can see[/a]. The button has no border at the bottom of the button and the blue image background (members info and change your password) should be set to 25px in height, but in IE it doesn't use that height. Any ideas?

Here is my code html code for these tables:
<center>
<div class='member_wrap'>
<form action='./password_proccess.php' method='post'>
<div class='member_left'>
        <table class='main_table_members' cellpadding='0' cellspacing='1'>
        <tr>
        <td width='100%' class='table_top'>Members Info</td>
        </tr>
        <tr>
        <td class='column1' width='100%'><b>Welcome John Smith</b><br /><br />
        • <a href='/customers/help.php'>Help Page</a><br />
        • <a href='/customers/support.php'>Contact Support</a><br />
        • <a href='/customers/order.php'>Products</a><br />
        • <a href='/customers/email_edit.php'>Change my email</a><br />
        • <a href='/customers/password_edit.php'>Change my password</a><br />
        • <a href='/customers/logout.php'>Logout</a></td>
        </tr>
        </table>
</div>
<div class='member_right'>
        <table class='main_table_members' cellpadding='0' cellspacing='1'>
        <tr>
        <td width='100%' colspan='2' class='table_top'>Change Your Password</td>
        </tr>
        <tr>
        <td class='column1' width='50%' valign='top'><b>Your new password:</b></td>
        <td class='column2' width='50%' valign='top'><input type='password' name='password_edit' /></td>
        </tr>
        <tr>
        <td class='column1' width='50%' valign='top'><b>Confirm your current password:</b></td>
        <td class='column2' width='50%' valign='top'><input type='password' name='password_edit2' /></td>
        </tr>
        <tr>
        <td class='column1' width='50%' valign='top'><b>Confirm your current password:</b></td>
        <td class='column2' width='50%' valign='top'><input type='password' name='password_confirm' /></td>
        </tr>
        </table>
</div>
<br /><br /><input type="submit" value="Save Changes" />
</form>
</div>
</center>


Here is the css used:
.member_wrap {
    width: 98%;
    text-align: center;
}

.member_left {
    float: left;
    width: 28%;
    /*height: 100%;*/
    text-align: center;
}

.member_right {
    float: right;
    border: 0;
    width: 71%;
    text-align: left;
}

.main_table_members { 
    margin: 0;
    padding: 0;
    width: 100%;
    height: 200px;
    background-color: #FFFFFF;
    border: 1px solid #000000;
}

.table_top { 
    margin: 0;
    padding: 5px;
    height: 25px;
    text-align: center;
    background: #175299 url("/images/top_bg.gif");
    color: #FFFFFF;
    font-weight: bold;
    border: 0;
}

.column1 { 
    margin: 0;
    padding: 5px;
    text-align: left;
    background-color: #dbdbdb;
    border: 0;
    vertical-align: top;
}

.column2 { 
    margin: 0;
    padding: 5px;
    text-align: left;
    background-color: #cbcbcb;
    border: 0;
}

.column3 { 
    margin: 0;
    padding: 5px;
    text-align: left;
    background-color: #e3e3e3;
    border: 0;
}


Thanks

#2 homchz

homchz
  • Members
  • PipPipPip
  • Advanced Member
  • 93 posts
  • LocationLee, New Hampshire

Posted 19 June 2006 - 09:34 PM

looks like a padding issue

add this

form{
padding:0px;
margin:0px;
}

and see what happens.

Josh

#3 aaron118

aaron118
  • Members
  • PipPipPip
  • Advanced Member
  • 30 posts

Posted 19 June 2006 - 09:54 PM

Ok I have tried that, didn't change it. Any other ideas?

Thanks

#4 homchz

homchz
  • Members
  • PipPipPip
  • Advanced Member
  • 93 posts
  • LocationLee, New Hampshire

Posted 19 June 2006 - 10:00 PM

just for giggles take the
<center></center>
out of the HTML so it aligns left and see what happens.

#5 aaron118

aaron118
  • Members
  • PipPipPip
  • Advanced Member
  • 30 posts

Posted 19 June 2006 - 11:06 PM

Doesn't change the problem, just aligns the two tables to the left.

#6 homchz

homchz
  • Members
  • PipPipPip
  • Advanced Member
  • 93 posts
  • LocationLee, New Hampshire

Posted 19 June 2006 - 11:10 PM

if I have time later and it is not fixed i'll play with it on my machine.

#7 aaron118

aaron118
  • Members
  • PipPipPip
  • Advanced Member
  • 30 posts

Posted 19 June 2006 - 11:55 PM

Thanks I really appreciate it!

#8 nogray

nogray
  • Members
  • PipPipPip
  • Advanced Member
  • 930 posts
  • LocationSan Francisco CA

Posted 20 June 2006 - 12:44 AM

I don't see any style for the button in the code you posted, but IE will hide the border if the inside content is a tiny bigger than the actuall container.

You can fix it by removing the height of the button and just setting the padding-top and padding-bottom.

Also, you need to clear the floated layers before the button
.clear_div {font-size:1px;
     overflow:hidden;
     clear:both;}
</div>
<div class="clear_div">&nbsp;</div>
<input type="submit" value="Save Changes" class="button" />
This should fix the firefox issue

NoGray.com


#9 aaron118

aaron118
  • Members
  • PipPipPip
  • Advanced Member
  • 30 posts

Posted 20 June 2006 - 11:00 AM

Thanks alot mate, that has fixed the button issue. I have learnt from that so I will know in the future. Any idea on how to fix my height issue in IE?

Thanks again

#10 nogray

nogray
  • Members
  • PipPipPip
  • Advanced Member
  • 930 posts
  • LocationSan Francisco CA

Posted 20 June 2006 - 04:38 PM

I cannot find your button style in the code you posted, so I cannot really find the bug. Just a random guess,

Try to remove the height out of the style, and add padding to the top and bottom.

If you can post the style for the button, I may find the bug.

NoGray.com


#11 aaron118

aaron118
  • Members
  • PipPipPip
  • Advanced Member
  • 30 posts

Posted 20 June 2006 - 05:58 PM

What button style, I do not have one?

Thanks

#12 aaron118

aaron118
  • Members
  • PipPipPip
  • Advanced Member
  • 30 posts

Posted 21 June 2006 - 10:59 AM

Any idea?




0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users