Home > Contents > Index >
Expanded TOC   |    Purpose TOC   |    Annotated TOC   |    Index

 

AssetGetSiteParent

Loads the parent page of the specified page asset into memory as the Asset object.

Syntax

Parameters

authusername (required)
(String) Name of the user to log in, as registered in Content Server.

authpassword(required)
(String) Password for the associated user name.

TYPE (required)
(String) The asset type of the asset that you want to retrieve from the database. For a web service, the value must be page.

Typically, you provide TYPE and OBJECTID. When you know that a specific field/value pair can uniquely identify the asset, you can provide TYPE and the field/value pair instead. Either the OBJECTID or the FIELD and VALUE combination, but not both, are required to load an asset.

OBJECTID (optional)
(String) The unique identifying number that references the Asset object. Not required if you use TYPE with the FIELD and VALUE paired parameters (defined below).

FIELD (optional)
(String) A field is any one of the column names for the asset. For example, standard fields for CS-Direct assets include name, template, status, description, subtype, category, modified, headline, byline, and body. Use the field name in conjunction with the VALUE parameter as the name portion of a name/value pair. The field name and its corresponding value uniquely identifies the asset to be loaded. Note that if the field/value pair that you supply identifies more than one asset, the AssetLoad operation uses the first one that it finds.

Not required if you use TYPE with the OBJECTID parameter.

VALUE (optional)
(String) Value that corresponds to the field specified by the FIELD parameter. Paired with the field name, uniquely identifies an asset by supplying its associated value.

Not required if you use TYPE with the OBJECTID parameter.

EXCLUDE (optional)
(Boolean) Depending on whether the value of EXCLUDE is True or False, this operation either returns the fields specified in the FIELDLIST parameter or returns the fields not contained in the list.

True indicates that all fields except the fields in the FIELDLIST are to be returned.

False indicates that only fields in FIELDLIST are to be returned. That is, it returns fields specified with the FIELDLIST parameter. The default value is False.

FIELDLIST (optional)
(String) Comma-separated list of fields that you want to include or exclude from the request for asset fields. The EXCLUDE parameter, which operates on the field list, determines whether the fields in the list are returned or whether all fields other than those in the list are returned.

Description

This operation queries the SitePlanTree table and then loads, as an object, the parent page of the specified page asset. It functions like AssetLoad.

You typically use this operation to display information about the hierarchical position of the current page, for example, to create a link to the current page's parent page. This operation determines the parent page and then loads the parent page.

Returns

Asset object that represents the site parent.

errno

The possible values of errno include:

Value Description
-112 No parent exists.
-10001 The implementing class is invalid.
-10002 There is a missing operation for the implementing class.
-10003 The operation could not be invoked successfully.
-10004 A required parameter is missing.
-10005 The requested object is not in the object pool (is not loaded into memory).
-10006 The object ID is not valid.
-10007 The version of the object is not valid.
-10008 The node ID of the object is not valid.
-10009 More than one object met the specified criteria.
-12007 The specified value is not valid.

 

Example

This code loads a page asset, loads its parent page, extracts the name of the parent page asset, and then displays the name:

 

  Home > Contents > Index >

FatWire Web Services Reference
Copyright 2005,2006,2007 by FatWire Software
All rights reserved.