help required filtering in jquery

help required filtering in jquery

Hi, 

i want to use filter in jquery but not gtting how to proceed with it. i have written below script.

actually i want to do is, on click of .leftSelect i want to hide the current div and show previous. but only if parent is  talkNowOptionsSkip i want to show some other div. this is not working which i have written below:

  1. $(".leftSelect").click(function(){
  2. $(this).closest('.closed').hide();
  3. $(this).closest('.pushLeftPressed').prev().show();
  4. });
  5. $(".talkNowOptionsSkip .leftSelect").click(function(){
  6. $(this).closest('.closed').hide();
  7. $(".talkNowOptionsCheck").show();
  8. });