Google Maps のマーカーサイズを変更する

Enfoldのソースを直接改変
/wp-content/themes/enfold/config-templatebuilder/avia-shortcodes/google_maps/google_maps.php

$image = wp_get_attachment_image_src($shortcode['attr']['marker'], ‘thumbnail’);

$image = wp_get_attachment_image_src($shortcode['attr']['marker'], ‘fullsize’);

この部分は add_filterで差し替えられないので。

function avf_template_builder_shortcode_elements_mod($elements) {
if($elements[2]['name'] == ‘Add/Edit Map Locations’) {
foreach($elements[2]['subelements'] as $key => $options) {
foreach($options as $name => $value) {
if($options['name'] == ‘Custom Map Marker Image Size’) {
$elements[2]['subelements'][$key]['subtype'] = array (
’20px * 20px’ => ’20′,
’30px * 30px’ => ’30′,
’40px * 40px’ => ’40′,
’50px * 50px’ => ’50′,
’60px * 60px’ => ’60′,
’70px * 70px’ => ’70′,
’80px * 80px’ => ’80′,
’160px * 160px’ => ’160′,
);
}
}
}
}
return $elements;
}
add_filter(‘avf_template_builder_shortcode_elements’, ‘avf_template_builder_shortcode_elements_mod’, 10, 1);