vozzek Posted January 3, 2009 Share Posted January 3, 2009 Happy weekend all, I was wondering the best way to do the following: <div class="wrapper"> <div class="left"> <div class="right"> </div> <div> <div> "wrapper" has a fixed width of 790px. The width of "left" will be dynamic... anywhere from 200 all the way up to 580px. I need the width of class "right" to be 790 - (minus) the width of "left". For example if "left" was 580px, I would need to set "right"'s width to 210px. Is there a way to figure this in PhP? Thanks in advance! Quote Link to comment Share on other sites More sharing options...
revraz Posted January 3, 2009 Share Posted January 3, 2009 $left = 580; $right = (790-$left); Quote Link to comment Share on other sites More sharing options...
vozzek Posted January 3, 2009 Author Share Posted January 3, 2009 I guess I should've mentioned, I need to determine the width of an <img> that'll be assigned to the "right" class. The image is what could be any size width. Quote Link to comment Share on other sites More sharing options...
revraz Posted January 3, 2009 Share Posted January 3, 2009 $right would be that width. Quote Link to comment Share on other sites More sharing options...
DarkSuperHero Posted January 3, 2009 Share Posted January 3, 2009 how about making a php page with all your css and having your script inthere.... when the php script prints all the css...in nice plain readable nothing more than css... :-) Quote Link to comment Share on other sites More sharing options...
vozzek Posted January 3, 2009 Author Share Posted January 3, 2009 Awesome guys thanks, I ended up using the getimagesize() function. Much appreciated! Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.