We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 37582
    • 65 Posts
    In Drupal and ExpressionEngine there is a concept called Content types. With it, you can define which fields will be associated to resources. From a usability point of view it is not always necessary to have resources with all the standard content fields provided.

    Let me give an real life example: I want to display a group of people as a list in the frontend. Each list item consists of their profile picture, their name and their date of birth. Now, in my backend section I want to manage each of them individually. So I'll go with getResources, make each of them a separate resource, create a custom template with variables for their name, their picture and their date of birth. I could also take their name from the the title field or whatever. These resources will be children of one container, which I use as the parent for my getResources call.

    Now, when adding a new member to this group, I always need to assign that special template to this resource and use e.g. the title field for the name of the person.

    Is there any way to determine a special content type "person", define my mandatory fields and assign this to the parent resource container?
      • 1778
      • 659 Posts
      Hi,
      You can also do that this way : display a group of people as a list in the frontend. Each user name could be a link to only one resource (let say "InfoUser") with a specific template with only the fields you want to display.
      On click on the link you pass username or id as an URL parameter, and then display the related information in your unique resouce "InfoUser"... If you have plenty of users your solution involve the creation of plenty resources (one by user), not sure it's very efficient...
        • 37582
        • 65 Posts
        Hey anso,

        thanks for your reply. Basically, to me it seems like your suggestion only adds another dimension: The display of a resource (i.e. group member) as unique web page.