How to?
JS:
Update
To get the href attribute of links inside the icon box content elements using jQuery, here's a script example with detailed logging:
/* [JS] make whole icon box clickable */
jQuery(function ($) {
$(".make-iconbox-clickable .elementor-icon-box-content").each(function () {
var $originalLink = $(this).find("a");
if ($originalLink.length) {
var href = $originalLink.attr("href");
var anchorInner = $originalLink.html();
// Clone all attributes from original
var attributes = "";
$.each($originalLink[0].attributes, function () {
attributes += this.name + '="' + this.value + '" ';
});
$(this).find(".elementor-icon-box-title").html(anchorInner);
// Wrap the whole .elementor-icon-box-content content with new having the same attributes
$(this).wrapInner("");
}
});
});
Example:
Legal
Learn More