- This topic has 2 replies, 2 voices, and was last updated 9 months ago by .
We are running a dog shelter. I am building a website where our ‘doctors’ (users) can browse ‘dogs’ (custom post type 1) on the dogs archive page in the front end.
With a form on the single page of the dog, the doctors should now be able to add a new ‘medical report’ (custom post type 2).
This new ‘medical report’ entry should then be ‘attached’ to the dog. So a relationship between the dog and the medical report should be created when saving the form.
This allows our doctors to look for a dog in the front-end, create a new medical report for that dog and attach it to the dog. I then can show all medical reports related to a dog on the dog’s single page.
I am aware of the ‘MB relationship plugin’.
But I don’t know how to create a relation between the two custom post types ‘dog’ and ‘medical report’ and then use a frontend form, so it automatically creates a relationship between the two entries.
THX for your help!
- You must be logged in to reply to this topic.