how to put image and text on same line [closed]

This is most likely due to differing line-heights and font-sizes between the editor, and the live site. You can try setting the vertical-align on the image (middle), or css position: relative, and setting bottom or top plus or minus a number of pixels. If you do this often, it would be easiest to define a css class and assigning the class to the images.

<img class="inline-image" src="https://wordpress.stackexchange.com/questions/178866/...">

<style>
.inline-image {
   position: relative;
   top: -3px;
}
</style>