Want to count duplicate value from column using jQuery

109
January 23, 2020, at 11:10 PM

in my PHP table i have three column. one column have numeric value other two have alphabetic value. each column have duplicate value. i want to count duplicate value in each column. through php i did successfully but i need jquery. here is my logic. in php i used "mysql_num_rows(). in jquery what should i use.

$(document).ready(function() {
      var col1 = 0;
      var col2 = 0;
      var col3 = 0;
      var total = 0;
      $('tbody tr').each(function() {
        col1 = $(this).find('td').eq(0).text();
        col2 = $(this).find('td').eq(1).text();
        col3 = $(this).find('td').eq(2).text();
        var visano = $('#r_$c"."_1').text();
        var country = $('#r_$c"."_2').text();
        var category = $('#r_$c"."_3').text();
        var rows = $(col1).text() == $(visano).text() && $(col2).text() == $(country).text() && $(col1).text() == $(category).text();

console.log(rows);

      });
READ ALSO
jquery typeahead set static first element and then order asc the others

jquery typeahead set static first element and then order asc the others

I have a problem which I can't figure outI'm using jquery typeahead from runningcoder (http://www

132
how to disable all remaining numbers once 5 random number as been selected

how to disable all remaining numbers once 5 random number as been selected

This is the javascript I am using to pick the numbers by adding class active to any selected numbers, I use the javascript math to pick 5 numbers and add active class to any clicked number, but I want to disable all remaining numbers once 5 numbers has been selectedthanks...

93
what if xhr.onreadystatechange is not used in code

what if xhr.onreadystatechange is not used in code

I want to remove all consolelog() from my code, but I'm stuck in one case

90