dspObjects - Mura Docs v7.0

dspObjects

A Mura Scope helper method to dynamically output the display objects assigned to display regions.

Function Syntax

m.dspObjects( columnID )

Parameters

Parameter Type Req/Opt Default Description
columnID numeric Req  

Enter the desired display region number as defined under Site Settings > Edit Settings, Display Regions tab. The region number is determined by "^" delimited list position of Display Region Names, starting with "1" (not zero). For example, if the Display Region Names were "Left Column^Main Content^Right Column" and you wanted to output display objects assigned to the "Main Content" region, you would pass the number "2" for the columnID parameter.

Usage

Use this function to output display objects assigned to specific display regions.

Examples

The following example outputs display objects assigned to the second display region as defined under Site Settings > Edit Settings, Display Regions tab, Display Region Names list position.

<cfoutput>
<article class="display-objects-wrapper">
#m.dspObjects(2)#
</article>
</cfoutput>

Default Settings Example

The following is merely a simple reference to output the display regions as initially set up in Mura. However, you will want to verify your settings defined under Site Settings > Edit Settings, Display Regions tab, and adjust accordingly.

<cfoutput>
<!--- Left Sidebar/Column Display Objects --->
<aside class="left-sidebar display-objects-wrapper">
#m.dspObjects(1)#
</aside>
<!--- Main Content Display Objects --->
<article class="main-content display-objects-wrapper">
#m.dspObjects(2)#
</article>
<!--- Right Sidebar/Column Display Objects --->
<aside class="right-sidebar display-objects-wrapper">
#m.dspObjects(3)#
</aside>
</cfoutput>