Home › Forums › ACF PRO › if (have_rows()) not working › Reply To: if (have_rows()) not working
I’m also having what seems to be a similar issue.
The setup is the following:
– I have a Flexible Content field called “gallery”.
– On the homepage I call have_rows(“gallery”) to show the gallery associated to the homepage.
– I now want to have a separate div for the mobile version of the site which shows the first gallery field for each project (I’ve setup a custom post type called “work”). I use a custom WP_Query to get the required posts of the homepage. This works as expected, but if I then use have_rows(“gallery”) within the WP_Query this seems to completely break WordPress, the page never actually loads, it’s probably stuck in some sort of redirect.
Here is one error from the PHP log:
[10-Dec-2015 18:11:29 UTC] PHP Fatal error: Maximum execution time of 30 seconds exceeded in /Volumes/Date/Dropbox/htdocs/blid/wp-content/plugins/advanced-custom-fields-pro/api/api-template.php on line 552
(the code line varies from what I’ve seen logged)
Does this help in explaining the problem?
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.