Documentation Center

Upgrading Template Building Blocks when upgrading from SmartTarget 2011 SP2

If you are upgrading from SmartTarget 2011 SP2, you need to move your old SmartTarget Template Building Blocks to a backup folder and then use the Create Default Building Blocks command in Template Builder, which creates a new set of Template Building Blocks. After running this command, you can choose to keep continuing the old, deprecated Template Building Blocks, or you can migrate to the new Template Building Blocks, as SDL recommends.

About this task

If you are upgrading from SmartTarget 2011 SP2, note the following Templating Building Block changes that have taken place:
Product releaseChanges introduced
SDL SmartTarget 2014All the default SmartTarget Template Building Blocks were changed, except Add to SmartTarget.
SDL SmartTarget 2014 SP1The Add SmartTarget Query Template Building Block adds the pageId attribute to the <tcdl:query> tag produced by the template. As a result, you can filter the Page on Promotions (optional) and Experiments (required).
SDL Web Experience Optimization 8All Template Building Blocks that mentioned SmartTarget were renamed.

Procedure

  1. Open Content Manager Explorer.
  2. Go to your Default Templates Folder and create a subfolder called OLD SmartTarget Templates.
  3. Move all your old SmartTarget default Template Building Blocks, except Add to SmartTarget, to the OLD SmartTarget Templates Folder.
  4. Reload your default Experience Optimization Template Building Blocks:
    1. Start Template Builder by selecting Start > SDL Web > Template Builder from the Windows menu.
    2. Select Tools > Create Default Building Blocks to load the Experience Optimization (and other) default Template Building Blocks.
    3. Select the parent Folder which contains the Folder Default Templates and click OK.
  5. Your Content Manager instance is now upgraded. If you want, you can complete the process by migrating your code, instead of staying with your now deprecated, old Template Building Blocks. To migrate your templating code, do the following:
    1. In your templating code, replace or remove your old Template Building Block, referring to the following table:
      Template Building Block in SmartTarget 2011 SP2 and olderEquivalent Template Building Blocks in SDL Web Experience Optimization 8
      Add SmartTarget search promotionUse the following Template Building Blocks:
      • Add Experience Optimization Query
      • Search Experience Optimization
      • Add Promotions
      • Apply Experience Optimization Settings
      Add SmartTarget item promotionCreating an Item Promotion is no longer directly supported
      Add SmartTarget facet promotionCreating a Facet Promotion is no longer directly supported
      Set SmartTarget Page ViewCreating a Page View Promotion is no longer supported
    2. In your templating code, identify the tcdl tags below and replace them with Template Building Blocks as indicated:
      FunctionalityImplementation in SmartTarget 2011 SP3 and olderImplementation in 2014 and higher
      Navigation<tcdl:navigation> tags in Dreamweaver TemplatesTo generate navigation links in your published Web pages, use the following Template Building Blocks:
      • Add Experience Optimization Query
      • Show Experience Optimization Navigation
      • Apply Experience Optimization Settings
      Search<tcdl:items> and <tcdl:search> tags in Dreamweaver TemplatesTo implement search in your published Web pages, use the following Template Building Blocks:
      • Add Experience Optimization Query
      • Search Experience Optimization
      • Show Experience Optimization Items
      • Apply Experience Optimization Settings
  6. To use the filtering introduced in SDL SmartTarget 2014 SP1, republish your Web pages when you start adding Experiments, or earlier if you want to use filtering on Promotions.