How to make two charts using highchart show up in the same line side by side using div


I want to display two charts in the same line using div. Can you please help?

Here is the what I am trying but it shows up in 2 lines.

<script src=""></script>
<script src=""></script>
        <div id="container" style="width: 200px; height: 200px; diplay:inline"></div>
        <div id="container2" style="width: 200px; height: 200px; display:inline"></div>


full code in

Just float the containers left!

Either give both #container and #container2 a left float:

#container2 {
    float: left;


Or give both containers a class (say, "container") and float that class left:

.container {
    float: left;


Edit: display: inline-block will also work, as @Nile has pointed out. It's a matter of personal preference: I tend to prefer floats; some people, inline-blocks. For more information on which to use, you might want to check out this post: float:left; vs display:inline; vs display:inline-block; vs display:table-cell;.


display: inline-block;

Modified example:

By : Nile

This video can help you solving your question :)
By: admin