Use the Scenarios > Slots screen in the ATG Control Center to create and configure slot components for the Publish Web Content campaign action. The following configuration settings are required:

Note that using a session-scoped slot may cause errors similar to the following to appear in the console. The campaign is not affected.

Error    Invalid attempt to resolve component /atg/registry/Slots/<slotname> in scope global. It is defined in scope session
Error    /atg/dynamo/servlet/pipeline/RequestScopeManager/
RequestScope-218/atg/userprofiling/ProfileFormHandler
No slot component found at path /atg/registry/Slots/<slotname>

The following JSP snippets show you how to render binary and text slot content.

Binary Content JSP Example
<dsp:droplet name="/atg/targeting/TargetingForEach">
   <dsp:param bean="/atg/registry/Slots/exampleBinarySlot" name="targeter"/>
       <dsp:param name="howMany" value="1"/>
<dsp:oparam name="empty">
          Empty Slot rendered
</dsp:oparam>
<dsp:oparam name="output">
  <img src="<dsp:valueof param="element.url"/>">
</dsp:oparam>
</dsp:droplet>
Text Content JSP Example
<dsp:droplet name="/atg/targeting/TargetingForEach">
<dsp:param bean="/atg/registry/Slots/exampleTextSlot" name="targeter"/>
<dsp:param name="howMany" value="1"/>
<dsp:oparam name="empty">
  Empty Slot rendered
</dsp:oparam>
<dsp:oparam name="output">
   <dsp:valueof valueishtml="true" param="element.data"/>
</dsp:oparam>
</dsp:droplet>

Note the use of valueishtml="true" above. The text content is created using an HTML editor, and if you do not include this attribute, HTML tags appear on the page when the slot is rendered.

To learn more about slots, see the ATG Personalization Programming Guide and the ATG Personalization Guide for Business Users. To learn more about creating personalization assets for use in campaigns, see the ATG Content Administration Guide for Business Users.