Home › Forums › Front-end Issues › Google map address › Reply To: Google map address
Thank you so much! It took a little finagling, but I figured it out. I’m using the Options page add-on, and calling the company address into the footer. Here is the final code that did the trick:
<?php
// vars
$contact_address = get_field('company_address', 'option');
?>
<address class="footer-address street-address">
<?php $address = explode( "," , $contact_address['address']);
echo $address[0].', '; //street number
echo $address[1].','.$address[2]; //city, state + zip
?>
</address>
I really appreciate the help! 🙂
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.