Home › Forums › Front-end Issues › Need Help with True/False Field › Reply To: Need Help with True/False Field
You must have changed the code somehow. I was browsing your site about 10-20 minutes ago and everything seemed to work. The advertising ones led to a new page, while the other ones expanded the image. I see that when I visit your site now, that’s all gone; all the items lead to a new page.
The code I provided above should work provided that the fields still have the same field names.
You could try 0 for false:
if (get_post_meta($post->ID, 'media', true) == '0' )
EDIT: I just browsed your site again and now it seems to work!
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!
Are you building WordPress sites with ACF and @BeaverBuilder, and wanted to use your ACF Blocks in both the block editor and Beaver Builder?— Advanced Custom Fields (@wp_acf) May 10, 2023
The BB team recently added support for using ACF Blocks in Beaver Builder. Check it out 👇https://t.co/UalEIa5aQi
© 2023 Advanced Custom Fields.