Difference between revisions of "Template:Unique values"

From HodHood
Jump to: navigation, search
($count[$v]['category'] = isset( $argv[3] ) ? explode( ', ', $argv[3] ) : null;)
Line 5: Line 5:
 
foreach ( $val as $v ) {
 
foreach ( $val as $v ) {
 
   if ( isset( $count[$v] ) ) {
 
   if ( isset( $count[$v] ) ) {
     $count[$v]++;
+
     $count[$v]['count']++;
 
   } else {
 
   } else {
     $count[$v] = 1;
+
     $count[$v]['count'] = 1;
 +
    $count[$v]['category'] = isset( $argv[3] )  ? explode( ', ', $argv[3] ) : null;
 
   }
 
   }
 
   //$count[$v][] = $page;
 
   //$count[$v][] = $page;

Revision as of 09:06, 23 February 2018