danknol Posted November 30, 2010 Share Posted November 30, 2010 I still do not have a handle on this, and it should be second nature by now, but would someone please explain the rule when spacing styled text vertically within a cell (using an external style sheet). I have been advised not to use "padding-top:" , but instead use "margin-top:" , but it has no effect. I simply wish to move the text downward 142 pixels. Here is the style sheet code: .const-copy { font-family: Arial; font-size: 15px; line-height: 18px; padding-right: 425px; margin-top: 142; text-align: left; letter-spacing: 0px; color: #555555; background-image: url(images/zen_main-tile.gif); background-position: top left; background-repeat: no-repeat;} And here is a look at the web page.View Website Link to comment Share on other sites More sharing options...
DizzyDan Posted November 30, 2010 Share Posted November 30, 2010 I think because you are using tables instead of divs it might have something to do with it. From what i have learned here using tables is the 'old fashon' way to build a website. In fact i dont even know the correct use of tables due to CSS.You would put the width, align, and others in the style sheet instead of in the html code like you would with tables.even the 'body {}' would just go in the style sheet Also, instead of writing: margin-left: 0px; margin-top: 0px; margin-right: 0px; margin-bottom: 0px; Just put margin: 0px; so you dont have to type it all out. Link to comment Share on other sites More sharing options...
thescientist Posted November 30, 2010 Share Posted November 30, 2010 tables are only frowned upon when they aren't used for what they are intended for, which is displaying tabular data. The same concept for using a table applies for a div. You need to create the markup tags for it using HTML, and then CSS can be used to style it. CSS didn't replace tables, as it's not a substitute for markup, and vice-versa. The point is they work hand-in-hand. Link to comment Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.