November 17th, 2003, 03:10 AM
absolute css style re-size question
Ok. I've started learning CSS, such as it is-in Dreamweaver MX. I have gotten as far as working with the style sheets and usually tried embedding them inside existing tables on the html page. Most of the time I would set the positioning to relative so that it would sit inside a specific row or column. Only problem is I want to be able to add scroll bars to the style (perhaps to at one point cut and paste blog content) and it seems like the only way to achieve this is to make the style absolute and type in the numeric values for the respective position on the page. That solved the scroll bar issue but now the CSS tables are fixed on the page and will not re-size with the browser window like my old tables used to do! So I guess my question is can I have my scrollbars and tables too? And if not, can my CSS styles be set to behave like the tables do?
thanks in advance.
November 17th, 2003, 05:57 PM
There are several issues here.
First, there is no particular need to use any but default static positioning in the problem you described.
Relative positioning means the position may be offset from its normal position in the flow. Its normal position is "saved" and not closed up.
Absolute positioning means that offsets are taken from the edges of the container. The natural position is not saved, and is closed.
Sizing need not be metric eg. 20px or 10 ems, etc. It may be a fraction of its container's size, 35%, for example.
Tables are deprecated as a layout method. Write structural HTML, and let CSS define how the structure is displayed.
Having said all that, here is an example of what you want. I have put the <div> in a cell, and it obeys the rules of <td>'s.
edit: damn typos!
Last edited by kk5st; November 17th, 2003 at 06:00 PM.
There are those who manage to build a web site without knowing what they're doing; thereby proving to themselves they do, indeed, know what they're doing.
My html and css workshop
, demos and tutorials.
Ask a better question
, get a better answer.
November 17th, 2003, 08:45 PM
thanks for that link, I'll try this with my code. If everything goes well I'll post the result and you can tell me how it looks. Peace.