Home › Forums › General Issues › Google Map Field and HEIGHT › Reply To: Google Map Field and HEIGHT
I needed this answer, too, so for posterity:
You need to get the field object:
$map_object = get_field_object('your_map_field_name');
That will give you all the field settings. e.g. print_r($map_object)
:
Array (
[key] => field_1234567890
[label] => Map
[name] => your_map_field_name
[_name] => your_map_field_name
[type] => google_map
[order_no] => 1
[instructions] =>
[required] => 0
[id] => acf-field-map
[class] => google_map
[conditional_logic] => Array (
[status] => 0
[rules] => Array (
[0] => Array (
[field] => null
[operator] => ==
)
)
[allorany] => all
)
[center_lat] =>
[center_lng] =>
[zoom] => 12
[height] => 300 (there it is, yay!)
[field_group] => 123
[value] => Array (
[address] => 123 Main St Anywhere USA
[lat] => 12.3456789
[lng] => -123.456789
)
)
ps – just realized this is exactly one year later. weird.
Welcome to the Advanced Custom Fields community forum.
Browse through ideas, snippets of code, questions and answers between fellow ACF users
Helping others is a great way to earn karma, gain badges and help ACF development!
We use cookies to offer you a better browsing experience, analyze site traffic and personalize content. Read about how we use cookies and how you can control them in our Privacy Policy. If you continue to use this site, you consent to our use of cookies.