Filter selected with not
Description
The following code shows how to remove element from the selected list by id.
Example
<html>
<head>
<script
src="http://ajax.googleapis.com/ajax/libs/jquery/1.11.1/jquery.min.js"></script>
<script type="text/javascript">
$(document).ready(function() {<!--from w w w .j a va2 s . com-->
$("p").not("#blue").css("color", "red");
});
</script>
</head>
<body>
<p>java2s.com</p>
<p id="blue">java2s.com</p>
<p class="green">java2s.com</p>
<p class="gray">java2 s.com</p>
</body>
</html>