This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
function my_facetwp_index_row($params, $class) { | |
if ('branch' == $params['facet_name']) { | |
$values = (array) $params['facet_value']; // an array of post IDs (it's already unserialized) | |
foreach($values as $val) { | |
$params['facet_value'] = the_field('martygeocoderlatlng', $val); | |
$params['facet_display_value'] = the_field('martygeocoderaddress', $val); | |
$class -> insert($params); // insert each value to the database | |
} |