New Community Website

Ordinarily, you'd be at the right spot, but we've recently launched a brand new community website... For the community, by the community.

Yay... Take Me to the Community!

The Community Blog is a personal opinion of community members and by no means the official standpoint of DNN Corp or DNN Platform. This is a place to express personal thoughts about DNNPlatform, the community and its ecosystem. Do you have useful information that you would like to share with the DNN Community in a featured article or blog? If so, please contact .

The use of the Community Blog is covered by our Community Blog Guidelines - please read before commenting or posting.

Advanced Dynamic Data / Dynamic Content - Understanding Content Type Scopes

In this blog I want to give you a deeper understanding of Dynamic Data (also called Dynamic Content - though that's not the same thing). It' a level 300 briefing so it's meant more for more experienced users. 

We'll start with the core problem and build up from that. A content-type defines what a piece of content (also called an Entity) should contain. A few examples: 

  1. A "Person" content-type might contain first-name, last-name, birthday, etc. 
  2. A "Product" content-type might contain a product number, price, etc.  
  3. A "ImageMetadata" content-type might contain the file itself, a title, created-date etc.  
  4. A "Page" content-type might contain the url, title, and permissions…  
  5. …while the "Permission" content-type might contain the who (group/person) and effective permission (read/write) 

This feels clear, right? Let's go a step deeper: 

  1. A system component like a view / template must also be defined, with information like name, template-file etc. Let's call this content-type "TemplateDefinition"  
  2. All fields of a content-type (like the first-name or birthday) have some common configuration like "Label" and "Description" - this information must be stored somewhere, and should ideally also be multi-language, versioned etc. - so this too should be defined in a content-type which we'll call "@All" - for Attribute-All  
  3. The AmountOfKids of a person may need some configuration just for the number like minumum 0, maximum 64 (world record) - which should not be in a @All content-type. So let's say this is stored in a content-type "@Number"  
  4. And the pipeline-configuration for the query "Get all references of the category in URL" must also be stored in a (actually various) content-types. Let's call that "PipelineConfiguration" 

This all seems straight forward and like basic database table design with a bit of "Dynamic" added. But if the normal user would see all the 50+ content-types needed for a full system to work, it would get very, very confusing. So it would scare the users, and very likely the user would change something (like the definition for @All) which she should never ever touch. 

This is why we introduced Scopes in 2sxc from the very beginning - and we kept them secret because we figured people don't need to understand this. But just recently I discussed sharing content-types (another topic for another blog) with Benoit and realized that keeping this a secret will prevent people from fully using 2sxc - so in 2sxc 8 we're coming out :). 

What is the scope? 

Technically it's just a text-value which each content-type has. Since the UI always retrieves content-types of a specific scope ("2SexyContent" by default), the user will never see the other content-types. Internally it also has a few affects - so the UI will always look for attribute-definitions in the System-scope.

The 4 Main Scopes 

As of now, we have the following scopes 

  • System - this contains the basic content-types like everything needed to define attributes (@All, @String, @string-dropdown, etc.). In general everything which the EAV-System (entity/attribute/value) provides is found in here. So this subsystem knows nothing about dnn or 2sxc, it's kind of like the engine or database behind all this  
  • SexyContent - containing everything you usually see - so the "SimpleContent" or things like that are found here. This is the default scope.  
  • 2SexyContent-System - here we keep system content-types specific to 2sxc - like the content-type for template-definitions  
  • 2SexyContent-App - content-types just for the app-configuration. Specifically the content-type AppSettings and AppResources, of which each app usually just has 1 content-item (entity) 

Looking at Content-Types of another Scope 

2sic 8 has a new advanced mode in the admin-area which you can get by Ctrl-Clicking anywhere. The round button is for changing scopes - type the desired scope name and see what comes. 

Understanding what you see in the System-Scope 

Most content-types will tell you they exist (like @String) and that there are many entities of this type which you can also edit. You'll also notice that most content-types cannot be reconfigured. This is because they are Ghost-Content-Types which are shared from a central definition (yes, another secret functionality I'll blog about soon). They exist here merely as an anchor for storing content-items, but the definition cannot be changed inside your app. You can recognize Ghost-Content-Types by the special icon and the fact that you cannot edit the field-definitions. 

Note that most of the data here is metadata for something. So looking at items of @String or even editing it can have funny effects, because each item of the type @String is used to configure the input of a string-type. Metadata-items can be recognized by the tag-icon beside it. You can see what object is being enhanced by hovering over the tag. And yes - Metadata is another one of the secret features I'll have to blog about sometime :). 

 So I hope this gives you a deeper understanding of the data-structures and possibilities in the EAV / 2sxc. I promise to blog about metadata, shared and ghost content-types as well as creating custom input fields soon. 

Love from Japan,

Daniel Mettler grew up in the jungles of Indonesia and is founder and CEO of 2sic internet solutions in Switzerland and Liechtenstein, an 20-head web specialist with over 800 DNN projects since 1999. He is also chief architect of 2sxc (see forge), an open source module for creating attractive content and DNN Apps.

Read more posts by Daniel Mettler


There are currently no comments, be the first to post one.

Comment Form

Only registered users may post comments.


Aderson Oliveira (22)
Alec Whittington (11)
Alessandra Davies (3)
Alex Shirley (10)
Andrew Hoefling (3)
Andrew Nurse (30)
Andy Tryba (1)
Anthony Glenwright (5)
Antonio Chagoury (28)
Ash Prasad (37)
Ben Schmidt (1)
Benjamin Hermann (25)
Benoit Sarton (9)
Beth Firebaugh (12)
Bill Walker (36)
Bob Kruger (5)
Bogdan Litescu (1)
Brian Dukes (2)
Brice Snow (1)
Bruce Chapman (20)
Bryan Andrews (1)
cathal connolly (55)
Charles Nurse (163)
Chris Hammond (213)
Chris Paterra (55)
Clint Patterson (108)
Cuong Dang (21)
Daniel Bartholomew (2)
Daniel Mettler (181)
Daniel Valadas (48)
Dave Buckner (2)
David Poindexter (12)
David Rodriguez (3)
Dennis Shiao (1)
Doug Howell (11)
Erik van Ballegoij (30)
Ernst Peter Tamminga (80)
Francisco Perez Andres (17)
Geoff Barlow (12)
George Alatrash (12)
Gifford Watkins (3)
Gilles Le Pigocher (3)
Ian Robinson (7)
Israel Martinez (17)
Jan Blomquist (2)
Jan Jonas (3)
Jaspreet Bhatia (1)
Jenni Merrifield (6)
Joe Brinkman (274)
John Mitchell (1)
Jon Henning (14)
Jonathan Sheely (4)
Jordan Coopersmith (1)
Joseph Craig (2)
Kan Ma (1)
Keivan Beigi (3)
Kelly Ford (4)
Ken Grierson (10)
Kevin Schreiner (6)
Leigh Pointer (31)
Lorraine Young (60)
Malik Khan (1)
Matt Rutledge (2)
Matthias Schlomann (16)
Mauricio Márquez (5)
Michael Doxsey (7)
Michael Tobisch (3)
Michael Washington (202)
Miguel Gatmaytan (3)
Mike Horton (19)
Mitchel Sellers (40)
Nathan Rover (3)
Navin V Nagiah (14)
Néstor Sánchez (31)
Nik Kalyani (14)
Oliver Hine (1)
Patricio F. Salinas (1)
Patrick Ryan (1)
Peter Donker (54)
Philip Beadle (135)
Philipp Becker (4)
Richard Dumas (22)
Robert J Collins (5)
Roger Selwyn (8)
Ruben Lopez (1)
Ryan Martinez (1)
Sacha Trauwaen (1)
Salar Golestanian (4)
Sanjay Mehrotra (9)
Scott McCulloch (1)
Scott Schlesier (11)
Scott Wilkinson (3)
Scott Willhite (97)
Sebastian Leupold (80)
Shaun Walker (237)
Shawn Mehaffie (17)
Stefan Cullmann (12)
Stefan Kamphuis (12)
Steve Fabian (31)
Steven Fisher (1)
Tony Henrich (3)
Torsten Weggen (3)
Tycho de Waard (4)
Vicenç Masanas (27)
Vincent Nguyen (3)
Vitaly Kozadayev (6)
Will Morgenweck (40)
Will Strohl (180)
William Severance (5)
What is Liquid Content?
Find Out
What is Liquid Content?
Find Out
What is Liquid Content?
Find Out