...

View Full Version : IE no / Firefox yes



Lambneck
05-11-2008, 11:13 AM
I am pretty new to CSS and wondering if someone
could explain why the following code works in firefox
but not in Internet Explorer...



<style>
#table1 {padding-top: 50px;
padding-right: 0px;
padding-bottom: 50px;
padding-left: 100px;
}
</style>

FWDrew
05-11-2008, 11:58 AM
<style type="text/css">
#table1 {padding-top: 50px;
padding-right: 0px;
padding-bottom: 50px;
padding-left: 100px;
}
</style>

Drew

BabyJack
05-11-2008, 01:22 PM
Or, if you have an external CSS file, remove the <style></style> tags. They are not needed as the encoding is CASCADING STYLE SHEET (.css). They also make a difference to
padding-left: 30px;
and
margin-top: 2em;

FWDrew
05-11-2008, 01:37 PM
They also make a difference to
padding-left: 30px;
and
margin-top: 2em;
..........what are you talking about....?

Drew

BabyJack
05-11-2008, 01:39 PM
It correctly positions them.

FWDrew
05-11-2008, 01:43 PM
It correctly positions them.

Again what are you talking about? Correctly positions what? Please elaborate as to what you are trying to say and how it relates to the OP :rolleyes:

Drew

BabyJack
05-11-2008, 01:45 PM
It correctly positions the
<p class="">
<div id="">

thingies to how many EM, PX, IN, CM, MM etc.. Dont know how I can explain it more!

FWDrew
05-11-2008, 01:48 PM
thingies
Is that the term? :rolleyes:

This has nothing to do with the OP, why dont you quit while your ahead.

BabyJack
05-11-2008, 01:49 PM
Its not the term, couldnt think of the word.

It does have something to relate to the OP. Im saying that <style></style isnt needed in CSS external files.

FWDrew
05-11-2008, 01:52 PM
Its not the term, couldnt think of the word.

It does have something to relate to the OP. Im saying that <style></style isnt needed in CSS external files.

Using the tags would make one assume that it was not a .css file. However, I guess pointing out the obious is somewhat relevant so I see your point for that.

All that gibberish about padding and the <p =""> tags had nothing to do with the OP and made no sense.

Im done with this thread, it was answered long ago.

Drew

BabyJack
05-11-2008, 01:53 PM
Ok, I knew what I meant - just that I can never think of the right words.

Lambneck
05-11-2008, 07:15 PM
I appreciate all the help,
however, I tried:


<style type="text/css">
#table1 {padding-top: 50px;
padding-right: 0px;
padding-bottom: 50px;
padding-left: 100px;
}
</style>


and still doesnt work in IE...
???

_Aerospace_Eng_
05-11-2008, 07:17 PM
Please post a link to your site or post the rest of your html. CSS without html is useless. You've given us just about nothing to work with. Help us help you.

Lambneck
05-11-2008, 09:33 PM
<style type="text/css">
#table1 {padding-top: 50px;
padding-right: 0px;
padding-bottom: 50px;
padding-left: 100px;
}
</style>


<table id="table1" width=700>
<tr>
<td>
</td>
Why does this work in Firefox but not IE?
</tr>
</table>

Arbitrator
05-11-2008, 09:56 PM
I am pretty new to CSS and wondering if someone
could explain why the following code works in firefox
but not in Internet Explorer...



<style>
#table1 {padding-top: 50px;
padding-right: 0px;
padding-bottom: 50px;
padding-left: 100px;
}
</style>
Internet Explorer doesnít support the application of padding to table elements up to, at least, version 7.

Just FYI, you could have shortened this code considerably as shown below.


<style type="text/css">
#table1 { padding: 50px 0 50px 100px; }
</style>



<style type="text/css">
#table1 {padding-top: 50px;
padding-right: 0px;
padding-bottom: 50px;
padding-left: 100px;
}
</style>While the type attribute is required per the HTML 4.01 specification and XHTML DTDs, this isnít the source of this cited issue.



<style type="text/css">
#table1 {padding-top: 50px;
padding-right: 0px;
padding-bottom: 50px;
padding-left: 100px;
}
</style>


<table id="table1" width=700>
<tr>
<td>
</td>
Why does this work in Firefox but not IE?
</tr>
</table>Please use comment tags (e.g., <!-- Why does this work in Firefox but not IE? -->) or move comments outside of your code when providing said code since we canít know if thatís literally part of the code or just something to help explain your issue.

_Aerospace_Eng_
05-11-2008, 10:40 PM
Also do you really need to use a table? Are you displaying data? If not then no need for the table.

BabyJack
05-12-2008, 05:24 PM
Yes, tables are deprecated and outdated now. Very few sites use them.

abduraooft
05-12-2008, 05:27 PM
Yes, tables are deprecated and outdated now.
tables are not depreciated. You have to use table to display tabular data.

BabyJack
05-12-2008, 05:29 PM
Yes, for layouts but not for data, thats what I mean ;)
Never was good at English :)

Lambneck
05-14-2008, 12:23 AM
How to do it without using tables?

abduraooft
05-14-2008, 08:58 AM
Get some standard layouts from http://bonrouge.com/3c-hf-fluid-lc.php



EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum