Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR HTML

make a div clickable

//html
 <div class="col-md-3" id="brwsAllSupp">
        <a href="your_link"><span class="divLink"></span></a>
        <label style="color: black; width: 100%">Browse All Suppliers</label>
        <p class="truckImg">
          <img src="assets/images/truck.png" /> <label style="color:black; font-size:15px; margin-left:20px;"> > </label>
        </p>
 </div>
 
 //css
 .divLink {
  position: absolute;
  width: 100%;
  height: 100%;
  top: 0;
  left: 0;
  z-index: 1;
}
Source by stackoverflow.com #
 
PREVIOUS NEXT
Tagged: #div #clickable
ADD COMMENT
Topic
Name
2+8 =