How to make a box expand a distance from the sides
I'd like to know how you make it so that a box(textarea) would expand to fill space, but from a certain pixel distance (not percentage) just enough to fit a menu on each side. Is this possible?
I've tried as many CSS properties as I could find, but none of them seem to work correctly. (note, I'm fine with using javascript if required)
开发者_StackOverflow社区My specific page: http://pastebin.com/5adPwXEE
Don't think you need javascript for this, you just need to isolate your chat division into a div
(which is exactly what they're for ;))
This div will be 100% wide by default - then you margin it on both sides to clear your 2 x absolutely positioned lists.. then the textarea
s that sit inside it can be 100% of the "chat div".. you then remove the padding off the body element as you don't need it
I added div class="chat"
and removed all unnecessary CSS
精彩评论