Critical error when customizing markers
-
Dear Tijmen,
We experience a critical site error when we try to customize the store markers on the map. This happens for category markers as well as a single stores.
This happens on a client site and on a clean installation.
Copied code block below from your documentation and inserted into functions.php. Other customizations seem to be working fine.add_filter( 'wpsl_store_meta', 'custom_store_meta', 10, 2 ); function custom_store_meta( $store_meta, $store_id ) { if ( function_exists( 'z_taxonomy_image_url' ) ) { $terms = wp_get_post_terms( $store_id, 'wpsl_store_category' ); if ( $terms ) { if ( !is_wp_error( $terms ) ) { if ( isset( $_GET['filter'] ) && $_GET['filter'] ) { $filter_ids = explode( ',', $_GET['filter'] ); foreach ( $terms as $term ) { if ( in_array( $term->term_id, $filter_ids ) ) { $cat_marker = z_taxonomy_image_url( $term->term_id ); if ( $cat_marker ) { $store_meta['categoryMarkerUrl'] = $cat_marker; } } } } else { $store_meta['categoryMarkerUrl'] = z_taxonomy_image_url( $terms[0]->term_id ); } } } } return $store_meta; }
I am dutch speaking perhaps contact via e-mail would speed things up?
The page I need help with: [log in to see the link]
Viewing 1 replies (of 1 total)
Viewing 1 replies (of 1 total)
- The topic ‘Critical error when customizing markers’ is closed to new replies.