phppup Posted August 5, 2021 Share Posted August 5, 2021 It seemed simple when I thought of it, but multiple variations are NOT producing the result I imagined. Essentially, I have a single table that I want centered on a webpage, with a second table to the right. <center><div> content </div> </center> <div style="float: right;"> content </div> I enclosed the tables in <div> tags but my results did not improve. I do not want two side by side tables that are centered. I am trying to have one centered table with a second to its right. Quote Link to comment https://forums.phpfreaks.com/topic/313500-a-div-next-to-a-div/ Share on other sites More sharing options...
maxxd Posted August 6, 2021 Share Posted August 6, 2021 You could use modern browser technology with flex or grid. Or add a third div to the left and use vw units to size all three. Quote Link to comment https://forums.phpfreaks.com/topic/313500-a-div-next-to-a-div/#findComment-1588883 Share on other sites More sharing options...
Heretic86 Posted August 15, 2021 Share Posted August 15, 2021 You can also try applying "display: inline-block;" to your div classes. Quote Link to comment https://forums.phpfreaks.com/topic/313500-a-div-next-to-a-div/#findComment-1589133 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.