Floating a div and a p?

I’m trying to make the image (inside <div class="card">) to float to the left of the text, so heres what I have so far

<p>
  <div class="card float-left" style="margin-right:10px">
    <div class="card-body">
      <img src="images/users/e87daccd5e0842bd357ebfde50dd3ab5ee71ea4bcc31d0a81a12f49c91bf8b50.jpg" alt="Thumbnail" class="img-fluid img-thumbnail" style="width:300px;margin-bottom:10px">
      <h6 class="text-secondary"><i class="fa fa-phone" aria-hidden="true"></i>&nbsp;&nbsp;(619) 942-6938</h6>
      <h6 class="text-primary"><i class="fa fa-at" aria-hidden="true"></i>&nbsp;&nbsp;lurtnowski@gmail.com</h6>
    </div>
  </div>          			  
  I like tu...
</p>

but it doesnt work


What is the correct way to do this (I didn’t think a <div> is allowed inside a <p>)

What does your CSS look like?

Here is a link to the site in question…

http://svr.teamluke.net/owner.php?id=1

coothead

thanks

I fixed the problem, (I didn’t use a <p> to enclose the <div> but simply got rid of that and made it so that a

<h6> followed the <div>

Off Topic

To format inline tags in your posts, you need to place a single backtick before and after each tag.

2 Likes

This topic was automatically closed 91 days after the last reply. New replies are no longer allowed.