Jump to content
Sign in to follow this  
phun-ky

problemer med css/form (firefox/iexplorer)

Recommended Posts

har et lite problem med form/div/css. har en liten logg inn/søk meny på siden. koden min er ikke semantisk riktig (form blandet inn sammen blandt tabels) og menyen blir forskjellig i 2 browsere. hvordan kan jeg løse dette?

 

sånn ser det ut i firefox, og det er sånn jeg vil at det skal bli i iexplore (med mere riktig kode)

 

 

 

firefox.png

 

 

 

sånn er det i iexplorer:

 

 

 

 

iexplore.png

 

 

 

blir liksom "ekstra plass" som ikke skal være der..

 

her er xhtml koden:

 

 

 

<div id="usermenu">
   	<div id="login01">
     <form name="form1" method="post" action="/b_signin.php">
     	<table width="100%"  border="0" cellspacing="0" cellpadding="0" align="center">
       <tr>

       	<td width="30%">brukernavn:</td>
       	<td width="25%">passord:</td>
       	<td width="30%"></td>
       </tr>
       <tr>
       	<td width="40%"><input name="email" type="text" class="inputmail" id="epost"/></td>
       	<td width="30%"><input name="passw" type="password" class="inputpass" id="pass"/></td>
       	<td width="30%" align="left"><input name="knapp" type="submit" class="knapp" value="logg inn"/></td>

       </tr>
     	</table>
     </form>
   	</div>
   	<div id="login02">
     <form name="sokemoto" method="post" action="/finn.php">
     	<table width="100%"  border="0" cellspacing="0" cellpadding="0" align="center">
       <tr>
       	<td width="70%">søk:</td>

       	<td width="30%"></td>        	
       </tr>
       <tr>
       	<td align="right"><input type="text" name="sokeid" class="soek"/></td>
       	<td align="center"><input type="submit" name="Submit" value="søk" class="knapp"/></td>
       </tr>
     	</table>  
     </form>
   	</div>    	
 </div>

 

 

 

og her er css'en:

 

 

BODY{
font-family: Lucida Sans Unicode;
font-size: 12px !important;  
/*	color: #2c404c;  */
background-color:#ffffff;  
margin:0px auto 0px auto; 
padding:0px;
text-align:center;
}
#usermenu {
clear:both;
width:730px;
margin:0px auto 10px auto;
text-align:left;
padding:5px;
border:1px solid #000000;
background-color:#fff7eb;
height:50px;
}
#login01{
font-family:
Lucida Sans Unicode
;
font-size: 11px; 
color:#000000;
float:left;
width:48%;
padding:5px;
height:30px;
margin: 0px;

}
.inputmail {  
width:100px;  
font-family:
Lucida Sans Unicode
;
font-size: 12px;  
color:#000000;  
border:1px dashed #000000;  
background:#FFFFFF;  
padding:2px;
background-color:#FFFFFF;
}
.inputpass {  
width:80px;  
font-family:
Lucida Sans Unicode
;
font-size: 12px;  
color:#000000;  
border:1px dashed #000000;  
background:#FFFFFF;  
padding:2px;
}
.knapp {  
font-family:
Lucida Console
;
font-size: 12px;  
font-weight:bold;  
color:#000000;  
border:1px solid #000000;  
background:#ff9900;  
vertical-align:middle;
}
#login02{
font-family:
Lucida Sans Unicode
;
font-size: 11px; 
color:#000000;
float:right;	
width:48%;	
padding:5px;	
height:30px;
 margin: 0px;	
 }
.soek {  
width:250px;  
font-family:
Lucida Sans Unicode
;
font-size: 12px;  
color:#000000;  
/*	border:1px dashed #000000;  */
border: 1px solid #000000;
background:#FFFFFF;  
padding:2px;
}

 

 

 

noen som kan se hva som gjør at jeg får den ekstra spacen? og hvordan kan jeg fikse menyen slik at den blir som den er nå, uten tables?

Share this post


Link to post

Bruk "!important" for css i FF.

 

Eks.

 

.class {

padding: 10px !important; /* denne er for FF, Opera osv */

padding: 8px; /* denne er for IE */

}

Share this post


Link to post

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
Sign in to follow this  

  • Recently Browsing   0 members

    No registered users viewing this page.

×
×
  • Create New...