Answer the question
In order to leave comments, you need to log in
"Dynamic" url for background-image?
There are 6 such blocks on html:
<div class="teammate-1">
<div class="teammate-info-1">
<h4>AL RAYHAN <span>/ UI Designer</span></h4>
<p>Lorem ipsum dolor sit amet, consectetur adipisicing elit. Facere, blanditiis?</p>
<a href="#"><i class="fa fa-facebook" aria-hidden="true"></i></a>
<a href="#"><i class="fa fa-twitter" aria-hidden="true"></i></a>
<a href="#"><i class="fa fa-dribbble" aria-hidden="true"></i></a>
<a href="#"><i class="fa fa-envelope-o" aria-hidden="true"></i></a>
</div>
</div>
[class*="teammate-"]
background: url("../img/teammate1.jpg") no-repeat center center
background-size: cover
width: 370px
height: 440px
padding: 184px 20px 15px 20px
&:hover
[class*="teammate-info"]
opacity: 1
[class*="teammate-info"]
opacity: 0
width: 330px
height: 240px
padding: 40px
background-color: #70f6eb
transition: all 600ms ease-in-out
i.fa
padding-right: 12px
Answer the question
In order to leave comments, you need to log in
@for $i from 1 through 6 {
.teammate-#{$i} {
bacground-image: url('/images/teammate-#{$i}');
}
}
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question