It is hard explain what I am trying to build. So I will try to explain it via example.
Custom Post Type : Mobile
Assume that there there mobile posts..
- Nokia 6
- Samsung S 7
- Huawei P 10
- Apple iPhone 7
Custom Post Type : Compare
Following compare posts should be auto created..
- Nokia 6 vs Samsung S 7
- Nokia 6 vs Huawei P 10
- Nokia 6 vs Apple iPhone 7
- Samsung S 7 vs Huawei P 10
- Samsung S 7 vs Apple iPhone 7
- Huawei P 10 vs Apple iPhone 7
Every compare posts should be have two custom fields like mobile1
and mobile2
and it includes the post id of mobile post type.
Should building this type of thing is possible with WordPress? I have some ideas build it using cron... I mean reading Mobile Posts
and create compare posts.... But seems like it takes too much time... Is there any easy way?