var app = angular.module('plunker', []);
app.controller('MainCtrl', function($scope) {
$scope.search = '';
$scope.filterOnLocation = function(friend) {
return (friend.city + friend.address).indexOf($scope.search) >= 0;
};
});
<!doctype html>
<html ng-app="plunker">
<head>
<meta charset="utf-8">
<title>AngularJS Plunker</title>
<script>
document.write('<base href="' + document.location + '" />');
</script>
<!-- Latest compiled and minified CSS -->
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/css/bootstrap.min.css" integrity="sha384-BVYiiSIFeK1dGmJRAkycuHAHRg32OmUcww7on3RYdg4Va+PmSTsz/K68vbdEjh4u" crossorigin="anonymous">
<link rel="stylesheet" href="style.css">
<script src="https://ajax.googleapis.com/ajax/libs/angularjs/1.0.5/angular.js"></script>
<script src="app.js"></script>
</head>
<body ng-controller="MainCtrl">
<div class="container">
<div ng-init="friends = [{name:'John', phone:'555-1276',city:'new york', address:'10032, time street'},
{name:'Mary', phone:'800-BIG-MARY',city:'washington', address:'10054, star plaza'},
{name:'Mike', phone:'555-4321',city:'idaho', address:'54452, pizza hut'},
{name:'Adam', phone:'555-5678',city:'new york', address:'55032, wall street'},
{name:'Julie', phone:'555-8765',city:'idaho', address:'10032, time street'}]"></div>
<div class="col-md-12">Search:
<div class="form-group">
<input class="form-control" ng-model="search">
</div>
</div>
<table id="searchTextResults" class="table table-bordered table-hover">
<tr>
<th>Name</th>
<th>Phone</th>
<th class="highlight">City</th>
<th class="highlight">Address</th>
</tr>
<tr ng-repeat="friend in friends | filter:filterOnLocation">
<td>{{friend.name}}</td>
<td>{{friend.phone}}</td>
<td class="highlight">{{friend.city}}</td>
<td class="highlight">{{friend.address}}</td>
</tr>
</table>
</div>
</body>
</html>
/* Put your css in here */
.highlight{ background: #ff0;}