user7112108 user7112108 - 1 month ago 10
CSS Question

Make a border around a image for a profile picture using css/bootstrap

Hey guys I am trying to put a border around this image for something like this:border blue around picture Here is the code that I had tried also I would like for it to be in the left corner of the page. Thanks for the help in advance. Here's a preview of the code I have right now:https://jsfiddle.net/7hdrhs2r/3/
HTML:

<div class="container">
<div class="row">
<!-- Picture must be 600px X 600px-->
<div class="col-lg-5 col-xs-6" id="picturebox">

<img src="https://upload.wikimedia.org/wikipedia/commons/thumb/f/fa/Apple_logo_black.svg/600px-Apple_logo_black.svg.png" alt="profile pic" height="10%" width="10%"/>
</div>
</div>


CSS

#picturebox{
border-color:midnightblue;
margin: 0 auto;
border:10px solid #ccc;
border-right: 200%;
padding:20px 60px 0px 2px ;
height: 100%
width:50%;
background-color:lightblue;
}

Answer
#picturebox img {
  border: solid 3px red;
  padding: 5px;
  background-color: lightblue;
}

JSfiddle

Note: to comment out CSS, do this:

/* code */

Works with multiline comments as well:

/* code
code */