Welcome aboard! We are happy you are here and wish you good net-raft!
<!DOCTYPE html>
<html>
<head>
<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.1.1/jquery.min.js"></script>
<style>
.blue{
color: blue;
font-weight: bold;
}
</style>
<script>
$(document).ready(function () {
$("div:contains('IF')").each(function () {
$(this).html(function (index, text) {
return text.replace('IF', '<span class="blue">IF</span>');
});
});
});
</script>
</head>
<body>
<div class="test">THIS IS IF FUNCTION</div>
</body>
</html>
The most helpful JQUERY solutions
plugin get client ip address using jqueryJQUERY Click to see more ... 10.5K 1.8K