Reading from Advanced Custom Fields (ACF) and Custom Post Types
-
Hi
I am fairly new to WordPress and ACF in general and I am trying to do a website related to the movie industry.
I have succeeded in creating 2 Custom Post Types:
1. Movie Details – This is a Custom Post Type where all the details related to a movie are stored. To add certain movie specific data, I used ACF to create 2 basic fields:- Release Date (Type TEXT)
- Poster Image (Type IMAGE)
2. Movie List – This is a Custom Post Type where I show the movies in different lists, for example related to release date. In this custom post type, I have create the following ACF structure
- Movie List (Type REPEATER)
- Movie Name (Sub Field of type TEXT)
The idea is that through wordpress, display a list of lets say ‘2018 movies’. I would like to do the following:
1. Load a particular list(post ID) from the Movie List
2. Loop each Movie found in this Movie List (repeater)
3. For each Movie, while looping, get the Release Date and Poster Image from Movie Details.It might sound simple but I have spent many days trying to solve this with no luck!
Can you please help me out?
Thank you!
Ian
- The topic ‘Reading from Advanced Custom Fields (ACF) and Custom Post Types’ is closed to new replies.