Home › Forums › ACF PRO › Using post information in a widget › Reply To: Using post information in a widget
Hi @pixeldynamo
Within your widget code you must find a way to obtain the current $post ID. Then you can get ACF to return the correct data by using the second parameter of teh get_field function.
http://www.advancedcustomfields.com/resources/how-to-get-values-from-another-page/
Most likely you can find the $post with this:
global $post;
$post_id = $post->ID;
Good luck
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.