moldboy 0 Report post Posted October 23, 2005 Is it possable with CSS to say I want <<An item>> to be so wide, and no narrower, however if it should need to it can expand as much as I want? Or better yet, can expand only a certain amount?So a DIV would be 400px wide, by default however if 500px of text were inserted into it the DIV would expand it's boundries. Share this post Link to post Share on other sites
rvalkass 5 Report post Posted October 23, 2005 As far as I am aware there is a very simple way to set a minimum width, but this doesn't work with IE and I can't find a work around to get it to work. If you're still interested then the code is: div{min-width:400px;} As I said, this wont work with Internet Explorer and can play havok with site layouts and designs, so use at your own risk. Share this post Link to post Share on other sites
jlhaslip 4 Report post Posted October 23, 2005 http://forums.xisto.com/no_longer_exists/ http://forums.xisto.com/no_longer_exists/ Here is a better link for the css dimensioning properties. I'll ask the mods to delete the specific links for min-width and max-width since this new link is more informative and should be more helpful to yourself and others. The specific information for min and max sizes are also available on the w3schools site. Use the site search box in the top right corner. So, tweo things come out of this. The css for the element would become: element {min-width: 50%; max-width: 80%} and as reported by rvalkass below and on the chart at w3schools these properties are not supported by IE. Use it carefully. Sorry, bad link above. Try this one css dimensioning properties Notice from BuffaloHELP: Merged and edited as reported. Share this post Link to post Share on other sites
Tyssen 0 Report post Posted October 23, 2005 IE treats width & height as min-width and min-height. Using child selectors which IE doesn't understand, you can feed it and other browsers different rules, e.g.: body { width: 700px;}html>body { width: auto; min-width: 700px;}Max values are a bit trickier. Here's an article that explains on how to do it: http://forums.xisto.com/no_longer_exists/ Share this post Link to post Share on other sites
reatum 0 Report post Posted October 23, 2005 Check out CSS play for min-height and min-width. Share this post Link to post Share on other sites