Let's say I have an auction website:

  1. 'Ads' would be a section -> channel
  2. The ads in it would be entries in the channel

Let's say guest users can make an offer on the action/ad. I would like to save all the offers in the entry, so I could read them out front-end.

What would be the best way to save these entries? I'm having difficulty understanding this structure-wise.


Craft has a pretty extensive relationship system, which is what you'd probably want to take advantage of here.

You could make another channel called "Offers" and each offer would be an entry in that section.

Then you could create an entries field called "Ad" and save it in your "Offers" section's field layout and have its source set to "Ad".

Then, when saving an offer, you'd select the ad(s) in the ad field the offer belongs.

You'd be able to query those relationships from the template side like so: https://craftcms.com/docs/entries-fields#examples

| improve this answer | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.