Comparing a clicked views-row in a loop When I loop through my .views-row divs in jQuery, I need to 'grab' the one that is clicked on, needing to uniquely identify it and put only the selected fields from that particular div in my modal frame. Now I have the selected fields of all the divs within that loop in my modal frame.

I don't think I'm too far off with the following here below. I think the only thing that's missing is that I haven't been able to properly 'say' to drupal which div is being clicked and see to which views-row-number it corresponds to in order to display only that one in the modal frame.  

obviously jQuery(".views-row .views-row-" + index).click() isn't the way but I'm sortof out of ideas which one that would be then.

jQuery(document).ready(function(jQuery) {

    row = jQuery(".views-row");

    row.each(function(index){
        forModal = jQuery('.forModal');
        forModal.hide(); 
        jQuery(".views-row").click(function(){

                if (jQuery(".views-row .views-row-" + index) ==
                                jQuery(".views-row .views-row-" + index).click()){
                                 forModal.modal();
                }

        }); 
    });

});
I think you're making that a bit harder than it needs to be...if I understand you right anytime a row is clicked you want to identify that row, extract a field from it and display it in a modal?

If so something like this would be a bit simpler:

(function($) {
  $(function() {
    $('.views-row').click(function() {
      // Find the modal within this row and show it.
      $(this).find('.forModal').modal();
    });
  });
})(jQuery);


Sorry if I've mis-understood what you're looking for, I wasn't 100% sure.