This project is read-only.

Create content type with body, image gallery and another body?

Topics: Customizing Orchard, General
Jul 19, 2012 at 8:33 AM


I'm new to Orchard but after Umbraco dropped v5 I'm looking at other CMS options.

The architecture of Orchard is quite different from what I'm used to.

Suppose my website has serveral pages with the same layout: text, an image gallery and some more text. I want to create a content type for this.

However, the body content part can only be added once to a content type. So how can I place an image gallery between two chunks of text...?


Jul 19, 2012 at 8:58 AM

I created a custom field for that. Fields you CAN add multiple times.

Jul 19, 2012 at 9:10 AM

Create from scratch in VS you mean?

How would you get the wysiyg editor for the text part?

There's no way to combine the "body" and "image gallery" content parts into some entity that can be added multiple times to a content type out of the box?

Jul 19, 2012 at 9:12 AM

Not that I know of, no, and I just based myself on what they did with the BodyPart / TinyMCE module to get wysiwyg support.

Jul 19, 2012 at 9:20 AM

Any source you could share to get me started?

Jul 19, 2012 at 9:22 AM

That is going to be hard I fear, its tightly bound with the rest of our (closed source) project.

Maybe later on when I got time (going to take a while...) I'll release a module with our 'common' fields, but currently I have no time to split things up.

Jul 19, 2012 at 9:31 AM

No problem. I understand not everything is open source :)

Jul 23, 2012 at 12:12 PM

No need for a custom field. Just use a text field and configure it to use HTML.