Additional Reserved Attributes

In addition to the client-side reserved attributes describe above, FrontPage 98 introduced two other attributes that can be used to alter the behavior of a component.

Attribute Meaning
PageAspPrefix Whenever component software attempts to insert ASP at the very beginning of a document (not in the middle of the page, where the component itself resides), it can use this reserved attribute to specify that block of ASP code.

ASP prefixes appear at the top of the document in the same order as the components that generated them appear in the body of the document (so multiple PageAspPrefix-using components can appear on the same page). FrontPage keeps track of all the ASP prefixes it is responsible for by inserting a special comment into the ASP code that begins with

' FP_ASP
. Also, if not already present,
<%
and
%>
are added before and after the ASP provided in the attribute.

The PageAspPrefix attribute is only checked when the component returns from its server-side

expand( )
function, and once the attribute is read and the ASP is inserted at the top of the page, the attribute is stripped out of the component attribute list. This means that the PageAspPrefix attribute never actually appears in the component WEBBOT syntax. It also means that the component
expand( )
function must add the attribute each time it returns, or else the ASP will not be regenerated. Note that the ASP-code referred to by PageAspPrefix must start with
<%newline,
or the prefix becomes wrapped in
<%newline and %>
.

SuggestedExt When a component is inserted into a page, it can request that FrontPage use a particular file extension when the page is saved by using the SuggestedExt attribute. If the page has not yet been saved, FrontPage will use this attribute to propose a file extension in the SaveAs dialog. If the page has already been saved with a different extension, FrontPage will display a message instructing the user how to change the file extension. SuggestedExt is particularly useful when a component relies on a technology that requires a certain file type extension, such as ASP.