LAYOUT COMMAND EXAMPLES

The following code fragments describe the use of Page Layout commands for a variety of uses in Page Layout templates and Edit Layout templates. Go to Choosing/uploading images for examples of how to manipulate images within Edit Layout templates.

This document provides the following examples that show how to allow a content contributor to either make a choice or enter data:

  • Choosing to Include a previously published HTML code fragment
  • Creating a hyperlink reference from a published content choice list
  • Entering a limited amount of data into a document body
  • Entering larger amounts of Text and/or raw HTML data into a document body
  • Using the WYSIWYG editor to enter content into an area in the document body
  • Creating a document property for use in feeding an ASP dynamic content server

Choosing to Include a previously published HTML code fragment

<!-- The following HYPERLINK control allows the user to select from a list
     of templates stored in a user-defined "code-fragment" directory -->
<!--[type=HYPERLINK
     name="Overview"
     prompt="Select a story overview:<br>"   
     prefix="$docroot" mime="*"
     dir="/news/lead_story_overviews"]-->
<!-- $docroot"" -->
<$include $docroot>
<!--[END]-->
… more HTML code …


Creating a hyperlink reference from a published content choice list
 
<!-- The following HYPERLINK control allows the user to select from a list of
     published documents in several directories to assign it’s location to a URL
     surrounding previously defined HTML code provided by the Page Layout
     template designer  -->
<!--[type=HYPERLINK
     name="Other_Story"
     prompt="Select a Reference<br>"
    dir="/Improve,/Galaxy,/Travel"]-->
<a target="Reference" href="">Click here for associated story!</a>
<!--[END]-->
… more HTML code …

 

Entering a limited amount of data into a document body 
 
!-- The following EDIT control allows the content contributor to enter a news release
      date that will be displayed on the published page -->
<!--[type=EDIT
     name="News_Release_Date"
     prompt="News Release Date:<br>"
     width=25]-->
(Enter Monthname dd, yyyy)
<!--[END]--></font>
… more HTML code …

Entering larger amounts of Text and/or raw HTML data into a document body 
 
!—The following control provides a text entry area of 12 lines, 80 character wide,
       to allow a content contributor to enter text and/or raw HTML commands -->
<!—[type=TEXTAREA
      name=”Raw_HTML” 
      prompt=”Enter text and/or HTML here:<br>”
  Width=”80”
      height=”12”
      wrap=”soft”]-->
<!—[END]-->
… more HTML code …

Using the WYSIWYG editor to enter content into an area in the document body 
 
!--[type=HTMLEDIT
     name = "Story"
     prompt="Enter the body of your story:<br>"
     dir="/wsd-samples/images"
     width=PREFWIDTH
     pixelwidth=100%
     pixelheight=360
     height=30
     wrap=SOFT]-->
<!--[END]-->
… more HTML code …

Remember: You can use the editliveflags= and/or ewebeditproflags= attributes to control which WYSIWYG tools are available to your content contributors using WYSIWYG controls to enter data!

Creating a document property for use in feeding an ASP dynamic content server 
 
!--[type=EDIT
     name="Title" 
     hidden

     prompt="Title: "
     property="paramTitle"
     width= 20]-->
<!--[END]-->
<!-- LinkTitle=<$prop:paramTitle$> -->
<%
       Dim form_display_title
       form_display_title = "<$prop:paramTitle$>"
%>
<!--#include virtual="/includes/form_header.asp"-->
… more HTML code …

Copyright 2000-2005 CyberTeams, Inc., http://www.cyberteams.com All rights reserved.
CyberTeams and WebSite Director are registered trademarks of CyberTeams, Inc. All other marks are the property of their respective owners.