I am currently trying to create a grid-layout with HTML/CSS only for various of reasons (I know Bootstrap etc. but that's no option in this context & and I can not add markup elements).
I have the following code (container div with each time a title which has an ul with li's):
<div>
<h3>title here</h3>
<ul>
<li>list-item</li>
<li>list-item</li>
<li>list-item</li>
</ul>
<h3>title 2 here</h3>
<ul>
<li>list-item</li>
<li>list-item</li>
</ul>
<h3>title 3 here</h3>
<ul>
<li>list-item</li>
</ul>
</div>
Now I'd like to be able to create a grid-layout. Meaning e.g. each title is 33% width so I can have 3 next to eachother.
Problem is that there is an ul in between each time. So is there a possible floating solution so I can have a grid layout as result.
TITLE - TITLE - TITLE
ul ul ul
-
h3 {
width: 33%;
float: left;
display: inline-block;
}
ul{
float: left;
width: 33%;
display: inline-block;
}
and all of this without a framework.
Thanks in advance