Hello Friend, how are you?
For you to count views or downloads of the pdf file, you need to change the workflow you have developed.
Today, you provide the user with the direct link to the file (pdf or otherwise), so you can’t know who clicked or not.
My suggestion to solve your problem, and first you create a template or a wp_ajax that receives by parameter the file that needs to be downloaded (or the post_id linked to the file).
This adds +1 to the preview field and then redirects the user to the final file link.
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!
© 2022 Advanced Custom Fields.