40 Publishing Content Using Content Presenter

In a Spaces application, you can add content from one or more connected content repositories to the application, as described in Chapter 39, "Introduction to Adding and Managing Content."

This chapter describes how to publish content on a page in a Spaces application using the Content Presenter task flow:

Audience

This chapter is intended for Spaces users assigned, minimally, the Pages-Edit Pages permission who want to add content in a Content Presenter task flow to a page in a Spaces application.

40.1 What You Should Know About the Content Presenter Task Flow

Content Presenter enables you to precisely customize the selection and presentation of content in a Spaces application. The Content Presenter task flow is available only when the connected content repository is Content Server and your Spaces administrator has completed the prerequisite configuration.

With Content Presenter, you can select a single item of content, contents under a folder, a list of items, query for content, or select content based on the results of a Personalization Conductor scenario, and then select a template to render the content on a page in a Spaces application.

Note:

Content Server exposes a content item only after it has a revision status of Released. If a content item does not have Released status, you will not be able to configure Content Presenter to show the item. You can find the status of a content item in Content Server on the Content Information Page, as described in "Determining the Revision Status" in Oracle Fusion Middleware User's Guide for Oracle Content Server.

In addition to displaying the folders and files in Content Server, Content Presenter integrates with Oracle Site Studio to allow you to create, access, edit, and display Site Studio contributor data files in either a Site Studio region template or a custom Content Presenter display template. For more information, see Section 40.1.1, "Understanding Site Studio Integration."

Content Presenter has no dependency on the Documents service for adding or managing the content it displays.

40.1.1 Understanding Site Studio Integration

Oracle Site Studio is a powerful, flexible web development application suite that offers a comprehensive approach to designing, building, and maintaining enterprise-scale web sites. Site Studio uses Content Server as the main repository for a web site.

Site Studio region templates are defined in Site Studio Designer. They define the layout and look-and-feel of the data in contribution regions within web pages. They are partial HTML files in that they do not have a head and body section. At runtime, the Site Studio contributor data file (a Content Server document) is merged with the Site Studio region template to create the HTML fragment. This allows Site Studio region templates to be inserted into other HTML code as the web pages are generated for the Site Studio site.

Content Presenter integrates with Site Studio to allow you to create, access, edit, and display Site Studio contributor data files in either a Site Studio region template or a custom Content Presenter display template.

Note:

Oracle Site Studio files can also be included in the Folder Viewer, Document Explorer, and Document Manager task flows, and previewed using the Document Viewer. See Section 41.1.7, "Understanding the Document Viewer Task Flow."

Before you can display Site Studio contributor data files in Content Presenter, the WebCenter Portal administrator must complete the followings tasks, described in Oracle Fusion Middleware Administrator's Guide for Oracle WebCenter Portal:

For proper surfacing in Content Presenter, the following link types can be used in both Site Studio region templates, as well as in a Site Studio contributor data file:

  • Links to nodes in the default navigation model, as described in Section 40.7, "Adding Links from Content to Navigation Nodes."

  • Links to inlined images.

  • Links to documents (except for absolute or relative path links). When clicking the link at runtime, it renders within the context of the application and displays the document using the Default View display template.

  • Absolute HTTP links, whether created in Site Studio contributor mode or in Site Studio Designer region template HTML.

The following Site Studio link types are not supported in Content Presenter:

  • Links to Site Studio sections.

  • Absolute or relative path links to Site Studio documents.

For guidelines on authoring recommendations for displaying a Site Studio contributor data file in Content Presenter, see Section 40.8, "Authoring Site Studio Content to Optimize Presentation in Content Presenter."

You can create and edit Site Studio contributor data files from the Content Presenter Configuration dialog (see Section 40.9, "Creating or Editing Site Studio Content in the Content Presenter Configuration Dialog") or in-context when displayed in Content Presenter at runtime (see Section 40.10, "Creating and Editing Files In-Context in a Content Presenter Task Flow").

For more information about creating and using Site Studio contributor data files and Site Studio region templates, refer to the Oracle Site Studio documentation library.

40.2 Adding a Content Presenter Task Flow to a Page

To add a Content Presenter task flow to a page:

  1. Open the page in edit mode.

    See Also:

    For more information, see Section 17.3.1, "Entering and Exiting Page Edit Mode."

  2. Click Add Content in the target region to open the Resource Catalog.

  3. Navigate to the section of the Resource Catalog that provides access to the folders and files in the connected content repository.

    Tip:

    The presence or location of this section depends on how the Resource Catalog is configured. For example, in the default Resource Catalog, next to Content Management, click Open to expose the content selections (Figure 40-1).

    Figure 40-1 Opening the Content Management Section in the Resource Catalog

    Content Management Section in the Resource Catalog

    For information about the selections shown in the default Resource Catalog, see Section 39.2, "What You Should Know About Content Management Selections in the Resource Catalog."

  4. Add the Content Presenter task flow to the page in one of two ways:

    • Next to Content Presenter, click Add (Figure 40-2).

      Figure 40-2 Adding a Content Presenter Task Flow to a Page

      Oracle Composer Catalog: Add Content Presenter task flow

      A new empty region appears on your page (Figure 40-3).

      Figure 40-3 Adding a Content Presenter Task Flow to a Page

      Content Presenter empty region
    • Or, drill down in the Resource Catalog to the folder or file you want to display on the page: In the default Resource Catalog, next to All Content (or, in a Spaces application, Space Documents or Personal Documents), click Open until you locate the target content, then click Add, and choose Content Presenter from the menu (Figure 40-4).

      Note:

      Content Server exposes a content item only after it has a revision status of Released. If content item does not have Released status, you will not be able to configure Content Presenter to show the item. You can find the status of a content item in Content Server on the Content Information Page, as described in "Determining the Revision Status" in Oracle Fusion Middleware User's Guide for Oracle Content Server.

      Figure 40-4 Adding Content to a Content Presenter Task Flow

      Add Content Presenter task flow

      The selected folder or file displays in a default display template, as shown in Figure 40-5 and Figure 40-6.

      :

      Figure 40-5 Content Presenter Task Flow: Default Template for Word Document

      CP Task Flow: Default Template for Word Document

      Figure 40-6 Content Presenter Task Flow: Default Template for Image File

      CP Task Flow: Default Template for Image File

40.3 Displaying the Content Presenter Configuration Dialog

The Content Presenter Configuration dialog enables you to easily configure the Content Presenter task flow to select or change content, or choose a different display template.

Note:

You can also specify content and a display template by clicking the properties Edit icon (the second wrench icon in the task flow chrome) and specifying parameters on the Parameters tab of the Component Properties dialog. However, specifying parameters in this way is generally intended for use at design time by developers creating a WebCenter Portal: Framework application, or for advanced users who want to bind a parameter to an EL expression. If you modify a property value in the Component Properties dialog, the new value overrides the value specified in the Content Presenter Configuration dialog, and that value cannot subsequently be changed through the Content Presenter Configuration dialog. For information about Content Presenter task flow parameters, see Section 40.12, "Setting Content Presenter Task Flow Properties."

To display the Content Presenter Configuration dialog:

  1. In the Content Presenter task flow (see Section 40.2, "Adding a Content Presenter Task Flow to a Page"), click the task flow Edit icon (the first wrench icon in the task flow chrome) (Figure 40-7).

    Figure 40-7 Editing a Content Presenter Task Flow

    Edit Content Presenter task flow

    The Content Presenter Configuration dialog opens (Figure 40-8).

    Figure 40-8 Content Presenter Configuration Dialog

    Content Presenter Configuration dialog

    A green check mark alongside an item indicates that the required information is complete and valid.

40.4 Selecting Content

Note:

Content Presenter does not support non-ASCII characters in files that are encoded using the non-UTF-8 character encoding. When users preview such files in Content Presenter, non-ASCII characters appear garbled.

Depending on the type of content you want to display, follow the steps in one of the following sections:

40.4.1 Selecting a Single Content Item

To select a specific item (including a Site Studio contributor data file) to display in a Content Presenter display template or Oracle Site Studio region template (see Section 40.1.1, "Understanding Site Studio Integration"):

  1. In the Content Presenter Configuration dialog (see Section 40.3, "Displaying the Content Presenter Configuration Dialog"), click Select Content or the Content tab.

  2. On the Content page, expand the Content Source list, and select Single Content Item (Figure 40-9).

    Figure 40-9 Selecting the Content Source: Single Content Item

    Selecting content source: Single Content Item
  3. Click Browse to locate the content item.

    Note:

    Content Server exposes a content item in the Browse list only after it has a revision status of Released. The revision status of a new content item changes from Done to Released after it has reached its specified release date (specified by the dInDate property). Content items that do not have Released status will not appear in the Browse list. You can find the status of a content item in Content Server on the Content Information Page, as described in "Determining the Revision Status" in Oracle Fusion Middleware User's Guide for Oracle Content Server.

    An alternative way to display a single content item in Content Presenter is to navigate to the file and select Content Presenter from its Add menu, as described in Section 41.3, "Adding a Selected Folder or File to a Page." However, even though you are able to select the content item in this way, it will display in Content Presenter only if it has a revision status of Released. If the content item has a different revision status, but had a status of Released in the past, then Content Presenter will display the Released version of the content item, not the latest version that is not yet released.

    If the Spaces application is connected to multiple Content Server repositories, the browse tree shows the parent folder for the current user, or for the current space, in the repository that is specified as the primary connection. To access other connected repositories, click the navigation icon in the toolbar to expose the VCR parent node. Click VCR to show all connected content repositories.

    Figure 40-10 Navigating to Other Content Repositories

    Navigating to Other Content Repositories

    Note:

    If the content repository includes an invalid type configuration, then no content displays when you click Browse. Instead, an error message reports Unable to retrieve content type information.

40.4.2 Selecting the Contents of a Folder

To select a folder to display its contents on a page (in the order stored in the folder) in a Content Presenter display template:

  1. In the Content Presenter Configuration dialog (see Section 40.3, "Displaying the Content Presenter Configuration Dialog"), click Select Content or the Content tab.

  2. On the Content page, expand the Content Source list, and select Contents Under a Folder (Figure 40-11).

    Figure 40-11 Selecting the Content Source: Contents Under a Folder

    Selecting the Content Source: Contents Under a Folder
  3. Click Browse to locate a folder. To select the folder as the content source, click in the folder row, not on the folder name (clicking the folder name navigates into the folder).

    If the Spaces application is connected to multiple Content Server repositories, the browse tree shows the parent folder for the current user, or for the current space, in the repository that is specified as the primary connection. To access other connected repositories, click the Show Hierarchy navigation icon to the left of the repository name to expose the VCR parent node. Click VCR to show all connected content repositories.

    Figure 40-12 Navigating to Other Content Repositories

    Navigating to Other Content Repositories

    Note:

    If the content repository includes an invalid type configuration, then no content displays when you click Browse. Instead, an error message reports Unable to retrieve content type information.

40.4.3 Selecting Content Based on the Results of a Query

To enter query criteria to refine the selection of the content to display in a Content Presenter display template:

  1. In the Content Presenter Configuration dialog (see Section 40.3, "Displaying the Content Presenter Configuration Dialog"), click Select Content or the Content tab.

  2. On the Content page, expand the Content Source list, and select Results of a Query (Figure 40-13).

    Figure 40-13 Selecting the Content Source: Results of a Query

    Selecting the Content Source: Results of a Query
  3. In the Results of a Query pane (Figure 40-14 and Figure 40-15), enter desired values in the fields that you want the query to retrieve, as described in Table 40-1.

    Figure 40-14 Results of a Query Pane: All Content Types

    Results of a Query Pane: All Content Types

    Figure 40-15 Results of a Query Pane: Selected Content Type

    Results of a Query Pane: Selected Content Type

    Table 40-1 Specifying Query Criteria for Results of a Query

    Element Description

    File Name

    Enter the name of a file in the specified Repository that you want to display in the selected template. You can use * as a wild card character to retrieve multiple files; for example: *.jpg.

    Keywords

    Enter any value that may be present in the content of the documents. The value may be one or more words or phrases. Keyword search requires full-text search to be configured in Content Server by enabling FullText Search Option, as described in "Configuring the Oracle Content Server Instance" in Oracle Fusion Middleware Installation Guide for Oracle Enterprise Content Management Suite.

    Content Type

    Choose All Content Types to retrieve content items regardless of the content type. Or, choose the name of a content type profile or Site Studio region template definition (see Section 40.1.1, "Understanding Site Studio Integration") defined in Content Server. A content type profile specifies properties that define a specific type of content (for example, a press release, or a news flash, or an image). The content type IDC:GlobalProfile is the name of a default content type profile defined in Content Server that can be applied if no other content type profiles are defined.

    Limit Results

    Specify the maximum number of content items to be returned by the query.

    Dates

    In the Created and/or Last Modified fields, select a modifier to search for content items matching an exact date (is), a following date (is after), a preceding date (is before), or a date between two other dates (is between), which adds an additional date field for entering the second date. Click the Select Date icon to select a date in the correct format (mm/dd/yy), for example 11/18/11, or enter a date manually.

    Users

    In the Created By (user who uploaded) and Last Modified By fields, enter a user name for the creator or last modifier of the content item, or click the Browse icon to open the Search Users dialog where you can select from a list of users or search for a user name. For tips on searching for a user in the identity store, see Section 52.3.4.1, "Searching for a User or Group in the Identity Store."

    Additional Query Filters

    Not applicable when Content Type is set to All Content Types. For a selected content type profile (prefixed IDC:), click the Add icon to list all the properties that are defined for the selected profile (Figure 40-15). Select one or more properties to refine the query to find content items with specific property settings.

    Sort Order

    Not applicable when Content Type is set to All Content Types. For a selected content type profile (prefixed IDC:), specify a sort order for the properties shown in the Sort On list.


  4. Click Preview Results to see the results of the query.

    Note:

    If the content repository includes an invalid type configuration, then no content displays when you click Preview Results. Instead, an error message reports Unable to retrieve content type information.

40.4.4 Selecting a List of Content Items

Content Presenter allows you to create a list of multiple content items. The order you use when creating the list is the order in which they are presented at runtime.

To browse or search for any number of items to add to a list, and delete or reorder the items before adding the list to a page in a Content Presenter display template:

  1. In the Content Presenter Configuration dialog (see Section 40.3, "Displaying the Content Presenter Configuration Dialog"), click Select Content or the Content tab.

  2. On the Content page, expand the Content Source list, and select List of Items (Figure 40-9).

    Figure 40-16 Selecting the Content Source: List of Items

    Selecting the Content Source: List of Items
  3. In the Select Items to Display pane (Figure 40-17), click Add to browse or search for any number of items to add to a list.

    Figure 40-17 Selecting Items to Display

    Selecting Items to Display

    If your Spaces application is connected to multiple Content Server repositories, the browse tree shows the parent folder for the current user, or for the current space, in the repository that is specified as the primary connection. To access other connected repositories, click the Show Hierarchy navigation icon to the left of the repository name to expose the VCR parent node. Click VCR to show all connected content repositories.

    Figure 40-18 Navigating to Other Content Repositories

    Navigating to Other Content Repositories

    Note:

    If the content repository includes an invalid type configuration, then no content displays when you click Browse. Instead, an error message reports Unable to retrieve content type information.

40.4.5 Selecting Content Based on the Results of a Scenario

If your Spaces application is configured to run Personalization Conductor scenarios using Content Presenter, you can select content based on the results of a WebCenter PersonalizationConductor scenario. For more information, see "Personalizing WebCenter Portal Applications" in Oracle Fusion Middleware Developer's Guide for Oracle WebCenter Portal and "Configuring Content Presenter" in Oracle Fusion Middleware Administrator's Guide for Oracle WebCenter Portal.

To enter Personalization Conductor scenario criteria to refine the selection of the content to display in a Content Presenter display template:

  1. In the Content Presenter Configuration dialog (see Section 40.3, "Displaying the Content Presenter Configuration Dialog"), click Select Content or the Content tab.

  2. On the Content page, expand the Content Source list, and select Results of a Scenario (Figure 40-19).

    Figure 40-19 Selecting the Content Source: Results of a Scenario

    Selecting the Content Source: Results of a Scenario
  3. In the Results of a Scenario pane, review the list of scenarios that have been tagged for Content Presenter consumption, select those for which you want to generate results, and enter required parameters (Figure 40-20).

    Figure 40-20 Results of a Scenario Pane

    Results of a Scenario Pane
  4. Click Preview Results to see the results of the selected scenarios.

    Note:

    If the content repository includes an invalid type configuration, then no content displays when you click Preview Results. Instead, an error message reports Unable to retrieve content type information.

    Any results that are returned from a scenario for use by Content Presenter must return a valid CMIS query, as Content Presenter takes the return value and runs it (as a CMIS query) against the repository specified within the Conductor URL. For information about how to format the query and examples, see Oracle Fusion Middleware Content Management REST Service Developer's Guide.

40.5 Selecting a Display Template

The display template for the content you have selected on the Content page of the Content Presenter Configuration dialog may be one of the out-of-the-box templates provided with Spaces (see Table 40-2 and Table 40-3), a custom template designed for your organization in JDeveloper, or a Site Studio region template (see Section 40.1.1, "Understanding Site Studio Integration").

For information about creating custom display templates in JDeveloper, and uploading them for use by your Spaces application, see "Creating Custom Content Presenter Display Templates" in Oracle Fusion Middleware Developer's Guide for Oracle WebCenter Portal. For information about creating and using Site Studio region templates, refer to the Oracle Site Studio documentation library.

By default, Spaces selects an appropriate display template based on the type of content selected. You can change the default template as required.

The Spaces administrator can show, hide, and manage the custom display templates on the Resources page of the application administration settings. For more information, see Section 10.4, "Managing Resources."

To change the display template for the selected content:

  1. In the Content Presenter Configuration dialog (see Section 40.3, "Displaying the Content Presenter Configuration Dialog"), click Select Template or the Template tab.

    The templates that are available for selection in the Template list are those that are identified by Content Presenter as suitable for displaying the selected content item(s). For more information, see "Identifying Display Templates for Selected Content Items" in Oracle Fusion Middleware Developer's Guide for Oracle WebCenter Portal.

  2. On the Template page:

    • If the Content Source selected on the Content page is a Site Studio contributor data file or any other single content item, select a Site Studio region template or a Content Presenter display template, respectively, from the Template list.

      The list of available Site Studio region templates includes only the templates that match the region definition of the Site Studio contributor data file selected on the Content page. To identify the Site Studio region templates, hover your mouse pointer over the templates in the list to display hint text identifying the Site Studio region templates. For more information, see Section 40.1.1, "Understanding Site Studio Integration."

      Note:

      If you create a Site Studio contributor data file directly from the Content Presenter Configuration dialog, as described in Section 40.9, "Creating or Editing Site Studio Content in the Content Presenter Configuration Dialog", the Site Studio region templates that match the region definition of the Site Studio contributor data file may not be immediately shown in the Template list. In this case, select the default template, and click Save. Then, open the Content Presenter Configuration dialog again to find the Site Studio region templates in the Template list.

      The Content Presenter display templates in the list include the out-of-the-box templates for single content items (see Table 40-2). Other selections that may be available in the list are custom display templates that the application administrator has uploaded to your Spaces application. For more information, see the "Creating Content Presenter Display Templates" chapter in Oracle Fusion Middleware Developer's Guide for Oracle WebCenter Portal.

      Figure 40-21 shows the Template list, with a Site Studio region template named PressReleaseFullDisplay selected.

      Figure 40-21 Selecting the Custom Display Template

      Selecting the Custom Display Template
      Description of "Figure 40-21 Selecting the Custom Display Template"

    • If the Content Source selected on the Content page is a multiple content item (Contents Under a Folder, Results of a Query, or List of Items), select the desired Template Category (Figure 40-22), then the Template (Figure 40-23).

      Figure 40-22 Selecting the Template Category (for Multiple Content Items)

      Selecting the template category

      Figure 40-23 Selecting the Display Template (for Multiple Content Items)

      Selecting the multiple content item template

      By default, there is only one category: Default Templates. This selection defines the collection of out-of-the-box templates available for multiple content items (see Table 40-3).

      Other selections that may be available are custom template categories and display templates that the application administrator has uploaded to your Spaces application. For more information, see the "Creating Content Presenter Display Templates" chapter in Oracle Fusion Middleware Developer's Guide for Oracle WebCenter Portal.

    Table 40-2 Out-of-the-Box Templates for Displaying Single Content Items

    Single Content Item Templates View ID Description

    Default Document Details View

    oracle.webcenter.content.templates.default.document.details

    Displays detailed information about any single content item including creation date, modification date, created by username, modified by username, path, and any comments.

    Default List Item View

    oracle.webcenter.content.templates.default.list.item

    Displays a single line with an icon and item name as a link that either displays or downloads the item when clicked.

    Default View
    (default when no template is selected)

    oracle.webcenter.content.templates.default.detail

    Displays any single content item, either directly in the browser (images, HTML, text) or as a link that downloads the associated file when clicked.

    For example, when the selected document type is .doc, the Default View template is assigned to be the Default Document Details View template.


    Table 40-3 Out-of-the-Box Templates for Displaying Multiple Content Items

    Multiple Content Item Templates View ID Description

    Accordion View

    oracle.webcenter.content.templates.default.list.panel.accordion

    Displays multiple content items in an accordion format, where each item can be expanded to display its details.

    Bulleted View

    oracle.webcenter.content.templates.default.list.bulleted

    Displays multiple content items in a bulleted list format. Only content items display; folder items are omitted.

    Bulleted with Folder Label View

    oracle.webcenter.content.templates.default.list.bulleted.label

    Displays multiple content items in a bulleted list format. The name of the folder containing the first item in the list displays as a label above the list. This template is intended to be used with Content Source set to Contents Under a Folder to ensure that all items have the same parent folder. Only content items display; folder items are omitted.

    Carousel View

    oracle.webcenter.content.templates.default.list.carousel

    Displays multiple content items in a carousel format, where items can be browsed by moving a slider left or right.

    Icon View

    oracle.webcenter.content.templates.default.list.tile

    Displays multiple content items in a tiled format with large icons and file names.

    List View
    (default when no template is selected)

    oracle.webcenter.content.templates.default.list.simple

    Displays multiple content items in a simple list.

    List with Details Panel View

    oracle.webcenter.content.templates.default.list.details.panel

    Displays multiple content items in a list on the left, with a panel to the right displaying the details of a selected item.

    Sortable Table View

    oracle.webcenter.content.templates.default.list.tabular

    Displays multiple content items in a sortable table that includes the document name, date created, and date modified.

    Tabbed View

    oracle.webcenter.content.templates.default.list.panel.tabbed

    Displays multiple content items as tabs that can be selected to display item details.


40.6 Previewing the Results

To see a preview of your selected content before adding it to the page:

  • Click Preview or the Preview tab.

The appearance of the content on the Preview page is dependent on whether the selected display template uses a stretch or flow layout. While the final view of the task flow can be configured to use either a stretch layout or a flow layout, the Preview page only uses a flow layout. As a result, the preview of content using templates that were designed for a stretch layout displays unstretched at a fixed default size. This is the normal behavior of stretchable content when displayed in non-stretching flow layout. To allow stretchable content to stretch to its full size and fill the task flow space entirely, click the Edit icon for the task flow to display the Component Properties dialog, and select the Stretch Content property (on the Display Options tab). For more information, see Section 17.5.2.5, "Working with Component Display Options."

Note:

Content Presenter does not support non-ASCII characters in files that are encoded using the non-UTF-8 character encoding. When users preview such files in Content Presenter, non-ASCII characters appear garbled.

From the Preview tab, you can click Edit Web Content (Figure 40-24) to edit HTML and Site Studio files in-context, as described in Section 40.10, "Creating and Editing Files In-Context in a Content Presenter Task Flow".

If the file is in workflow, you will see a workflow notification area at the top, as described in Section 40.11, "Approving and Rejecting Files in Workflow."

Figure 40-24 Previewing an Oracle Site Studio Contributor Data File

Previewing an Oracle Site Studio Contributor Data File

40.7 Adding Links from Content to Navigation Nodes

When you expose content stored in a Content Presenter task flow, consider whether or not you want to add one or more links from the content to a node in the default navigation model (see Section 11.2.2.1.8, "Setting Display Options for Navigation Items").

When the content displays in Content Presenter at runtime, an end user can click the links to navigate to the desired navigation model node.

You can create a link in the following content items in:

  • a document of MIME type text/html (typically HTML files)

  • a Site Studio contributor data file (in a Rich Text element)

  • a Site Studio region template

To add a link to a node in the default navigation model from a content item:

  1. Edit the content item, as described in:

  2. Add a link using the following syntax:

    $wcUrl('externalId')
    

    where externalId is the external identifier as configured in the Spaces default navigation model.

    For example:

    <a target="" href="$wcUrl('NEWCUSTOMERSLINK')">New Customers</a>
    

40.8 Authoring Site Studio Content to Optimize Presentation in Content Presenter

Content Presenter integrates with Oracle Site Studio to allow you to create, access, edit, and display Site Studio contributor data files in either a Site Studio region template or a custom Content Presenter display template. For more information, see Section 40.1.1, "Understanding Site Studio Integration."

To optimize the presentation of Oracle Site Studio content in Content Presenter, follow the guidelines provided in the following sections:

40.8.1 Best Practices for Images

Keep the following guidelines in mind as you work with images in Site Studio that will be displayed using Content Presenter:

  • Store images in Content Server in a common location (filed).

  • Insert images into WYSIWYG elements using the Site Studio Contributor image wizard.

  • Set the image tag src attribute to a relative link to an image file in Content Server. This attribute is rewritten by Content Presenter during rendering to use the GET_FILE service.

  • For performance improvement, use web proxy to cache artifacts at URLs from Content Server, and set expiration based on tolerance for updates in Content Server.

    Example for Apache mod_cache:

    • CacheEnable mem /cs

    • CacheDefaultExpire 3600 (one hour)

40.8.2 Best Practices for Defining Styles

Keep the following guidelines in mind as you work with style definitions for Site Studio contributor data files that will be displayed using Content Presenter:

  • Define styles in CSS files.

  • Store CSS files either in Content Server or in your Spaces application.

    • If stored in Content Server, add <link> in <head> of page template.

  • Load style class names into WYSIWYG region element definitions.

  • Select your CSS to format HTML in WYSIWYG elements.

  • For performance improvement, use web proxy to cache artifacts at URLs from Content Server, and set expiration based on tolerance for updates in Content Server.

    Example for Apache mod_cache:

    • CacheEnable mem /cs

    • CacheDefaultExpire 3600 (one hour)

40.8.3 Best Practices for JavaScript

Keep the following guidelines in mind as you work with JavaScript in Site Studio contributor data files that will be displayed using Content Presenter:

  • Recommended: Do not use JavaScript within web content that is rendered within Spaces applications.

  • If your web content uses JavaScript, follow these guidelines:

    • Add <link> in <head> of page template

    • For performance improvement, use web proxy to cache artifacts at URLs from Content Server, and set expiration based on tolerance for updates in Content Server.

      Example for Apache mod_cache:

      • CacheEnable mem /cs

      • CacheDefaultExpire 3600 (one hour)

40.9 Creating or Editing Site Studio Content in the Content Presenter Configuration Dialog

Content Presenter integrates with Oracle Site Studio to allow you to create, access, edit, and display Site Studio contributor data files in either a Site Studio region template or a custom Content Presenter display template. For more information, see Section 40.1.1, "Understanding Site Studio Integration."

Note:

To create or edit Oracle Site Studio content in a seamless interface within Spaces, both of the following two requirements must be met:

Without this configuration, it is still possible to create or edit Site Studio content from within Content Presenter, but the create and edit actions launch new browser windows (or tabs) rather than opening within the Content Presenter task flow.

To create or edit Oracle Site Studio content from the Content Presenter Configuration dialog:

  1. In the Content Presenter Configuration dialog (see Section 40.3, "Displaying the Content Presenter Configuration Dialog"), click Select Content or the Content tab.

  2. On the Content page, click Create Web Content (Figure 40-25).

    Figure 40-25 Selecting the Content Source: Site Studio

    Selecting the Content Source: Site Studio

    Tip:

    The Create Web Content button displays only when the Content Source field displays Single Content Item and when at least one Content Server repository (11g or higher) has the Site Studio component installed.

    The Oracle Site Studio Choose Region Content pane opens (Figure 40-26).

    Figure 40-26 Adding Site Studio Content: Choose Region Content

    Adding Site Studio Content: Choose Region Content
  3. In the Choose Region Content pane, select a Site Studio region definition on which the content you want to create or edit is based.

  4. Click Next.

    The Choose content file pane opens (Figure 40-27).

    Figure 40-27 Adding Site Studio Content: Choose Content File

    Adding Site Studio Content: Choose Content File
  5. In the Choose content file pane, select one of the following:

    • New Contributor data file to open the Check-in Content pane (Figure 40-28), where you can specify the standard document properties for the new Site Studio contributor data file that you want to check in to Content Server.

      Figure 40-28 Adding Site Studio Content: Check-in Content

      Adding Site Studio Content: Check-in Content
    • Existing file from server to open Content Server (Figure 40-29), showing Site Studio contributor data files that are based on the selected region definition.

      Figure 40-29 Content Server: Search Results

      Oracle Content Server: Search Results
  6. Make note of the file name, then click Next.

    The Check-in Confirmation pane opens (Figure 40-30).

    Figure 40-30 Adding Site Studio Content: Check-in Confirmation

    Adding Site Studio Content: Check-in Confirmation
  7. In the Check-in Confirmation pane, choose one of the following:

  8. Click Finish to return to the Content Presenter Configuration dialog.

    • If you access the Spaces application through Oracle HTTP Server (OHS) and have configured the webContextRoot parameter, as described in the Note at the top of this section, the Site Studio contributor data file you selected is shown auto-selected in the Content Presenter Configuration dialog.

    • If OHS and the webContextRoot parameter are not configured, you can now select the Site Studio contributor data file to display in the Content Presenter task flow: On the Content page, browse to the Site Studio file, select it, and click Select.

  9. In the Content Presenter Configuration dialog, click Save.

40.10 Creating and Editing Files In-Context in a Content Presenter Task Flow

In-context editing refers to editing content directly in a Spaces application at runtime, where the editor opens in a separate window.

With appropriate permissions, end users can edit HTML and Site Studio content in-context in a Content Presenter task flow.

Note:

Users must have permissions to view and edit the page containing the Content Presenter instance, as well as being assigned a role with write permissions on Content Server. For more information, see Chapter 20, "Understanding Security" and the chapter "Managing WebCenter Portal Application Security" in Oracle Fusion Middleware System Administrator's Guide for Oracle Content Server.

The following sections describe how to perform in-context editing:

40.10.1 Editing Wiki Documents or HTML Files In-Context

With appropriate permissions, end users can edit wiki documents or HTML files in-context in a Content Presenter task flow.

To edit a wiki or HTML file in a Content Presenter task flow:

  1. In the Content Presenter task flow, click anywhere in the file content.

  2. Press Ctrl-Shift-C to enter the in-context edit mode. The editable areas of the web page are highlighted with a dashed border.

    Note that you can change the key sequence to enter in-context edit mode if you wish. See Section 40.10.4, "Changing the Edit Mode Key Sequence."

  3. Click the Edit icon in the upper right corner of the document chrome (Figure 40-31) to open the file in the Document Viewer preview pane.

    Figure 40-31 Entering In-Context Edit Mode In a Content Presenter Task Flow

    Entering In-Context Edit Mode In CPTask Flow

    If the file is in workflowworkflow controls also display (Figure 40-32). For more information, see Chapter 43, "Working with Workflow-Enabled Content."

    Figure 40-32 Workflow Controls in In-Context Edit Mode in a Content Presenter Task Flow

    Worfklow Controls in In-Context Edit Mode
  4. In the Document Viewer preview pane, click the Edit action (Figure 40-33) to automatically check the file out and open it for editing in the Rich Text Editor (RTE).

    See Also:

    For information about the RTE, see Section 41.11, "Using the Rich Text Editor (RTE)."

    Figure 40-33 Opening the Rich Text Editor

    Opening the Rich Text Editor
  5. Make required updates, then save and close the file.

    The modified file is automatically checked back in.

  6. In the Content Presenter task flow in the Spaces application, press Ctrl-Shift-C again to exit the in-context editing mode.

40.10.2 Editing Site Studio Files In-Context

Content Presenter integrates with Oracle Site Studio to allow you to create, access, edit, and display Site Studio contributor data files in either a Site Studio region template or a custom Content Presenter display template. For more information, see Section 40.1.1, "Understanding Site Studio Integration."

With appropriate permissions, end users can edit Site Studio contributor data files in-context in a Content Presenter task flow.

To edit a Site Studio file in a Content Presenter task flow:

  1. In the Content Presenter task flow, click anywhere in the Site Studio file content.

  2. Press Ctrl-Shift-C to enter the in-context edit mode. The editable areas of the web page are highlighted with a dashed border.

    Note that you can change the key sequence to enter in-context edit mode if you wish. See Section 40.10.4, "Changing the Edit Mode Key Sequence."

  3. Click the Edit icon in the upper right corner of the document chrome (Figure 40-34) to open the file in Site Studio Contributor

    Figure 40-34 Entering In-Context Edit Mode in a Content Presenter Task Flow

    Entering In-Context Edit Mode In CP Task Flow
  4. In the Site Studio Contributor Data File editor, click a region to edit, as shown in Figure 40-35.

    For information about editing files in Site Studio Contributor, see the Oracle Site Studio documentation.

    Figure 40-35 Editing a File in Site Studio Contributor

    Editing a File in Site Studio Contributor
  5. Click Save And Close to exit the Site Studio Contributor editor and return to the Spaces application.

  6. In the Content Presenter task flow in the Spaces application, press Ctrl-Shift-C again to exit the in-context editing mode.

40.10.3 Creating New Site Studio Content In-Context

Content Presenter integrates with Oracle Site Studio to allow you to create, access, edit, and display Site Studio contributor data files in either a Site Studio region template or a custom Content Presenter display template. For more information, see Section 40.1.1, "Understanding Site Studio Integration."

With appropriate permissions, end users can create new web content in Site Studio during in-context editing in a Content Presenter task flow.

In-context creation of Site Studio files is slightly different than creating Site Studio files in the Content Presenter Configuration dialog, as described in Section 40.9, "Creating or Editing Site Studio Content in the Content Presenter Configuration Dialog." When creating a new Site Studio file in-context, you are limited to creating content that is of the same region definition, file location, security group, and document type as the content selected in the Content Presenter task flow.

To create a new Site Studio file in a Content Presenter task flow:

  1. In the Content Presenter task flow, click anywhere in the currently displayed Site Studio file.

  2. Press Ctrl-Shift-C to enter the in-context edit mode. The editable areas of the web page are highlighted with a dashed border.

    Note that you can change the key sequence to enter in-context edit mode if you wish. See Section 40.10.4, "Changing the Edit Mode Key Sequence."

  3. Click the Create icon in the upper right corner of the document chrome (Figure 40-36).

    Figure 40-36 Selecting the Create Icon in a Site Studio File

    Selecting the Create Icon in a Site Studio File
  4. In the Choose Content window, select New Contributor data file, then click Next (Figure 40-37).

    Figure 40-37 Choose New Content File Window

    Choose New Content File Window
  5. Fill out the Check-in Content form. This form provides the metadata for the contributor data file and checks the file into Content Server. The file is empty until you (or another contributor) edits it. For more information on filling out this form, see "Checking in Files" in Oracle Fusion Middleware User's Guide for Oracle Content Server.

  6. In the Check-in Confirmation window, select Edit content item now.

  7. Click Finish.

    The Site Studio Contributor Data File editor opens (Figure 40-38).

    Figure 40-38 Site Studio Contributor File Editor

    Site Studio Contributor File Editor
  8. Edit the file, then click Save and Close.

40.10.4 Changing the Edit Mode Key Sequence

To change the edit mode key sequence used to enter in-content editing mode for a Site Studio file in Content Presenter, edit the <key-sequence> entry in the application's adf-config.xml file:

******** Content Contributor Mode adf-config.xml entries ***************
 
<page-editor-config xmlns="http://xmlns.oracle.com/adf/pageeditor/config">        <content-contribution>          <enabled>true</enabled>          <key-sequence>ctrl shift C</key-sequence>        </content-contribution> </page-editor-config>

40.11 Approving and Rejecting Files in Workflow

You can view content items displayed in Content Presenter while they are in a workflow, including Site Studio contributor data files displayed in a Site Studio region template. As long as the content item has at some point had Released status in Content Server, you can display the content item in Content Presenter. Then, if a revision of the content item is pending in workflow, Content Presenter allows approvers for the content item to toggle between the published version and the version in workflow in page edit mode (Figure 40-39) or in-context edit (contributor) mode, and also provides links to approve or reject the item in workflow, and view additional details about the item (including workflow name, steps performed, action performed, date of action, and who performed the action).

Figure 40-39 Preview File in Workflow to Approve or Reject in Content Presenter

Page Edit Mode: Approve or Reject in CP

For more information about working with files in workflow in Content Presenter, see Section 43.3.2, "Viewing Workflow Files in a Content Presenter Task Flow."

40.12 Setting Content Presenter Task Flow Properties

The Content Presenter task flow has associated properties, which users with sufficient privileges can access through the Component Properties dialog in Composer (Figure 40-40).

Figure 40-40 Content Presenter Task Flow Component Properties

Content Presenter Task Flow Component Properties

For information about accessing the Component Properties dialog, see Section 17.5.2.3, "Setting Component Properties."

The following sections provide information about properties of the Content Presenter task flow and describe the properties on the Parameters tab:

40.12.1 What You Should Know About the Content Presenter Task Flow Properties

Note:

The Content Presenter properties are intended for use at design time by developers creating a WebCenter Portal: Framework application (see "Adding Content Task Flows and Document Components to a Portal Page" in Oracle Fusion Middleware Developer's Guide for Oracle WebCenter Portal), or for advanced users who want to bind a parameter to an EL expression. If you modify a property value in the Component Properties dialog, the new value overrides the value specified in the Content Presenter Configuration dialog, and that value becomes read-only in the Content Presenter Configuration dialog.

The properties on the Parameters tab of the Component Properties dialog control the default task flow content. For descriptions of the parameters on this tab, see Section 40.12.2, "Content Presenter Task Flow Parameters." For some task flows, parameters on this tab facilitate the wiring of the task flow to page parameters and page definition variables. For more information, see Chapter 19, "Wiring Pages, Task Flows, Portlets, and UI Components."

Changes to the properties on the Display Options, Style, and Content Style tabs affect the appearance and behavior of the task flow for all users. These properties are common to all task flows. For more information, see Section 17.5.2.5, "Working with Component Display Options" and Section 17.5.2.7, "Working with Style and Content Style Properties."

The contents of the Events tab depend on the events supported by the task flow. For more information, see Section 17.5.2.8, "Working with Component Contextual Events."

All properties on the Parameters and Display Options tabs provide access to an Expression Language (EL) editor, which you can use to select or specify a variable value instead of a constant value. Click the Edit icon next to a property field to open the editor. For more information about using the editor and for descriptions of common EL expressions, see Appendix B, "Expression Language Expressions."

40.12.2 Content Presenter Task Flow Parameters

Table 40-4 describes the parameters that are unique to the Content Presenter task flow.

Table 40-4 Content Presenter Task Flow Parameters

Parameter Description

Data Source

The data source of the content. The value depends on the value of Data Source Type:

  • When Data Source Type=Single Node, set Data Source to a single node identifier in the format:

    connection_name#dDocName:content_id

    For example: myconnection.myco.com#dDocName:STAN_IDC-007619

  • When Data Source Type=Folder Contents, set Data Source to a single node identifier in the format:

    connection_name#dCollectionID:collection_id

    For example: myconnection.myco.com#dCollectionID:45535

  • When Data Source Type=Query Expression, set Data Source to a CMIS (Content Management Interoperability Services) query expression.

    Examples:

    select * from cmis:document where cmis:name like \'test%\'

    connectionName=connection_name#select * from cmis:document where cmis:createdBy = \'weblogic\'

    Note: If connectionName is not specified, then the primary connection will be used.

    For more information about how to format the query and for more examples, see Oracle Fusion Middleware Content Management REST Service Developer's Guide.

  • When Data Source Type=Multi Node, set Data Source to a set of comma-delimited node identifiers in the format:

    connection_name#dDocName:content_id, connection_name#dDocName:content_id, ...

    For example: myconn#dDocName:DOCUMENT_ID_12345,myconn#dDocName:DOCUMENT_ID_56789

  • When Data Source Type=Scenario Results, set Data Source to the results from a scenario in the format:

    conductor-connection-name=conductor_conn_name,namespace=scenario_namespace,scenario-name=scenario_name,inputparm1=value1,inputparm2=value2, ...

    For example:

    conductor-connection-name=ConductorServiceLocal,namespace=CPNamespace,scenario-name=GetRelatedDocsScenario,topic=outdoors,interests=hiking

    For information about the Personalization Conductor and scenarios, see "Personalizing WebCenter Portal Applications" in Oracle Fusion Middleware Developer's Guide for Oracle WebCenter Portal.

Data Source (cont'd)

where:

  • connection_name = the name of the content repository connection.

  • content_id = the Content ID for the content specified on the content information page for the item in Content Server, or the CollectionID value on the content server.

  • collection_id = the dCollectionID found in the URL for the folder information page in Content Server.

  • conductor_connection_name = the name of the URL connection that points to the Personalization Conductor (this name must start with Conductor). This value must match the Reference name attribute value in the connections.xml file for this URL connection. For more information, see "Configuring Content Presenter" in Oracle Fusion Middleware Administrator's Guide for Oracle WebCenter Portal and the appendix "Files for WebCenter Portal Applications" in Oracle Fusion Middleware Developer's Guide for Oracle WebCenter Portal.

  • namespace = the name of the namespace that contains the specified scenario.

  • scenario_name = the name of the scenario that Content Presenter will be using.

Data Source Type

The data source type of the content. Corresponds to the Content Source value in the Content Presenter Configuration dialog. Valid values are:

  • Single Node: A single content item.

  • Folder Contents: The contents of a folder.

  • Query Expression: The results of a query.

  • Multi Node: An ordered list of content items.

  • Scenario Results: The results of the specified scenario created using the Scenario Editor in JDeveloper. See "Personalizing WebCenter Portal Applications" in Oracle Fusion Middleware Developer's Guide for Oracle WebCenter Portal.

Maximum Results

The maximum number of results to display when Data Source Type is Query Expression.

Default: 100

Region Template

Specifies whether the display template is a Site Studio region definition template. This value is valid only with Content Server 11g or higher:

  • ${true}: Display template is a Site Studio region definition template. The TemplateView ID value is set to the Content ID of the region template.

  • ${false} (default): Display template is not a Site Studio region definition template.

For information about creating and using Site Studio region templates, see Section 40.1.1, "Understanding Site Studio Integration" and the Oracle Site Studio documentation library.

Task Flow Instance ID

The unique identifier of this task flow instance, used internally to maintain the association of the task flow instance with its customization and personalization settings. Do not edit this value.

Template Category ID

The display template category ID to use in rendering results for multiple content items. This ID may reference the default template category for an out-of-the-box display template (Table 40-3) or a custom category created for a display template for multiple content items (see "Creating Content Presenter Display Templates" in Oracle Fusion Middleware Developer's Guide for Oracle WebCenter Portal).

Template View ID

The display template view ID to use in rendering results for single content items. Enter the view ID of a template that is configured in the Resource Manager for a specific content type, or for list-based templates by category ID. This ID may reference one of the out-of-the-box display templates (Table 40-2), a custom display template (see "Creating Content Presenter Display Templates" in Oracle Fusion Middleware Developer's Guide for Oracle WebCenter Portal), or set to the contentID of a region template if the content is a region.