Publishing tasks displayed to authors in the Authoring Connector Wizard are defined in a publishing task list that is set up by a site administrator. The publishing task list is an XML file called PublishingTasks.xml, located on the target server. This enables all clients connecting to the server to view the same list of publishing tasks. In order for a specific task list to be displayed in the Authoring Connector Wizard, the author must have rights to the channel and the template that are specified in the PublishingTask.xml document on the server. The default location of the XML document is <installation drive>:\Program Files\Microsoft Content Management Server\Server\IIS_CMS\OfficeWizard\PublishingTasks.xml.
NOTE: When multiple servers in a Web farm are used for authoring, copy the same PublishingTasks.xml file on all authoring servers to enforce consistency. Publishing Tasks Document StructureThe XML tasks list document is composed of a root element, <tasks>, and child elements, <task>. Each <task> element should contain four child elements, as follows:
For example, the following task list defines two publishing tasks, for creating a research page and for creating an article. <?xml version="1.0" ?> <tasks> <task> <name>Create a new research page</name> <description> This task creates a new research page </description> <template>/Templates/BOTS Consulting/Research</template> <channel>/Channels/botsconsulting/knowledge/research/</channel> </task> <task> <name>Create a new article</name> <description>This task creates a new article</description> <templateGuid> {ECF2A30B-7FBD-4771-B311-6C9551B2C2CF} </templateGuid> <channelGuid> {B5626CE8-CFA2-4578-86B8-7C2A2649A6FA} </channelGuid> </task> </tasks> The schema for the PublishingTasks.xml document is contained in the schema file PublishingTasks.xsd, located by default within the same folder. Each task has to follow the name, description, template, and channel order. The <name> and <description> elements can contain HTML escape markup. However, you need to make sure that all characters are properly escaped; otherwise, the XML document will not be valid. If any of the required elements are not defined or are defined wrongly, an error will occur and no tasks will be shown in the publishing task list. For example, if the <channel> element refers to a channel that does not exist, the publishing task will not be displayed to the authors.
NOTE: Searches by GUIDs are faster and require fewer resources on the server. Therefore, it is more efficient from a performance point of view to provide ChannelGUID and TemplateGUID values, rather than the virtual path locations of the channel and the template. Using GUIDs to define channels and templates also ensures that any naming changes to the site do not require modifications to the task list. When you create publishing tasks, ensure that the task names and descriptions clearly define the tasks for the nontechnical users. Creating and Modifying the Publishing TasksThe task list is an XML file that can be created or modified in Notepad or any XML editor. Also, you can download a GUI tool called the Publishing Task Editor from www.microsoft.com. The Task Editor is shown in Figure 7-21; it enables easier creation and modification of the PublishingTasks.xml file. Figure 7-21. Publishing Task EditorThere are two files that are required for the Task Editor: TaskEditor App.exe and tasklist.xsd. These two files must be located in the same directory. Also, CMS 2002 must be installed on the same computer; otherwise, the Task Editor will not function properly.
NOTE: The tasklist.xsd file, which is in the same directory as the Task Editor, is not exactly the same as PublishingTasks.xsd. However, both files adhere to the same standards for specified tasks. The Task Editor provides the following functionality:
NOTE: When you save the file in the Task Editor, the .xml extension is not automatically added; you need to type it in manually. The location of the PublishingTask.xml and PublishingTask.xsd documents can by modified by changing the web.config file in the Authoring Connector Web application. By default, they are located in the same directory as OC.aspx. This directory is mapped to the virtual directory /MCMS/CMS/OfficeWizard. However, for security reasons, it is recommended that you put these two files outside a virtual directory and specify their absolute path in the web.config file. System administrators may also choose to change the names of the files. The default location of the Authoring Connector's web.config file is <installation drive>:\Program Files\Microsoft Content Management Server\Server\IIS_CMS\OfficeWizard. The <appSettings> section within the <configuration> container defines the location and name of the publishing tasks and schema files. If this section is not present, the default location is used. However, the settings can be easily modified; for example: <appSettings> <add key="Publishing Tasks XML File Path" value="C:\secure\tasks.xml" /> <add key="Publishing Tasks Schema File Path" value="C:\secure\tasks.xsd" /> </appSettings>
NOTE: The value for the key attribute must be specified exactly as in the preceding code. Restricting Authors to Predefined Publishing TasksBy default, the Authoring Connector allows authors to manually select the template on which the page will be based and the channel into which the page will be posted. However, this manual override feature can be disabled, effectively restricting authors to use of the predefined tasks in the publishing task list. To disable the manual override option in the Authoring Connector Wizard, you need to make changes to the OC.aspx file.
NOTE: The modifications to the OC.aspx file are not supported by Microsoft, which means that changes to the OC.aspx file may be lost when you are applying service packs, hotfixes, or upgrades. Therefore, back up the original and modified version of the OC.aspx file before proceeding with any CMS update. After the update has been completed, you may be able to reapply your modifications in the appropriate sections. Using Visual Studio .NET or a text editor, open the <installation drive>:\Program Files\Microsoft Content Management Server\Server\IIS_CMS\OfficeWizard\OC.aspx file, and then locate and modify line 145 by adding the keyword disabled, so that it reads as follows: <td style="PADDING-TOP: 12px"><asp:checkbox disabled accessKey="M" runat="server" AutoPostBack="True" Text="<u>M</u>anual entry of channel and template"> </asp:checkbox></td> After you make this change, the "Manual entry of channel and template" check box in the Authoring Connector Wizard will be disabled, as shown in Figure 7-23. Figure 7-23. Manual override disabled |