Side bar acquiring whole body width, cannot insert any other contents on the same line

StackOverflow https://stackoverflow.com/questions/21799676

  •  12-10-2022
  •  | 
  •  

Question

I have created a sidebar in a php file, and included it in another webpage using 'include' syntax. The sidebar acquires only 20% of the body width, but I cannot put anything on the remaining 80%... Whatever I try to enter in those space, it comes in ONE LINE BELOW the sidebar. How do I correct it?

Was it helpful?

Solution

Use float: left; on both elements to stick them next to each other.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top