I have table structure like below, I am using PHP variable to store value, I want to add blink effect to complete row based on if the text contains in row is equal to PHP variable value then blink that row in green to some other color. I have tried below code but it only changes the background color of that cell only and not blinking effect to complete row. How to add blinking effect to complete row? Any help would be appreciated. Thanks in advance.
<html>
<head>
</head>
<title> Employee Data</title>
<?php
$empName = "Mr ABC";
?>
<table id="emp_data" class="table table-striped">
<thead>
<tr bgcolor="#E6E6FA">
<th>ID</th>
<th>Name</th>
<th>Email</th>
<th>Address</th>
</tr>
</thead>
<tr>
<td>20015</td>
<td class='grn'>Mr ABC</td>
<td>[email protected]</td>
<td>1 st, Mumbai, IN </td>
</tr>
<tr>
<td>20016</td>
<td class='grn'>Mr XYZ</td>
<td>[email protected]</td>
<td>1 st, Mumbai, IN </td>
</tr>
</table>
</html>
<script src="js/jquery-3.2.1.min.js"></script>
<script src="js/jquery-ui.js"></script>
<script type="text/javascript">
$(document).ready(function(){
$('#emp_data td.grn').each(function(){
var empName = '<?php echo $empName; ?>';
if ($(this).text() == empName) {
$(this).css('background-color','#080');
}
});
});
</script>