Content Studio Web Content Management System
Assembly: CSServer5 (in CSServer5.dll) Version: 5.7.5016.0 (5.7.5016.0)
Xml
Read permission is required on the objects in question.
When objectId represents a document, the returned value is the doctype used by this document. For containers
(categories, units and the site root) the returned value represents the doctype that containing documents will have.
A docType will be returned even if the document or category in question is of the binary
type or any other type that does not generate metadata.
[This is preliminary documentation and is subject to change.]
Returns the doctype in use by a either a document a category, unit or the site root.
Namespace: ContentStudio.Document
Assembly: CSServer5 (in CSServer5.dll) Version: 5.7.5016.0 (5.7.5016.0)
Syntax
public string GetForObject( ConnectionId connectionId, SessionId sessionId, int objectId, CSFileObjectTypes objectType )
Parameters
- connectionId
- Type: ContentStudioConnectionId
A value that identifies the web site - sessionId
- Type: ContentStudio.SecuritySessionId
A value that identifies the user's session. This value usually originates from a call to OpenSession(ConnectionId). - objectId
- Type: SystemInt32
An identifier to the object to return. - objectType
- Type: ContentStudio.DocumentCSFileObjectTypes
The type of object indicated by the parameter.
Return Value
Type: StringXml
Examples
<root> <status>0 </status> <statustext>Success</statustext> <data> <doctype id="integer value" inherited="bit value" inheritedfrom="string value" name="string value" declaration="string value" /> </data> </root>
Element/attribute | Type | Description |
---|---|---|
/root/status | integer value | indicates the outcome of the call, always 0 (meaning success) |
/root/statustext | string value | the textual representation of the outcome, always Success |
/root/data/doctype | Root element for the returned document type declaration | |
/root/data/doctype@id | integer | the id of the document type declaration |
/root/data/doctype@inherited | bit (0 / 1) | Indicates whether the document type declaration has been inherited from a parent object. |
/root/data/doctype@inheritedfrom | string | When inherited; the name of the object that defines the doctype; otherwise, empty |
/root/data/doctype@name | string | the name of the doc type e.g. XHTML 1.0 Transitional |
/root/data/doctype@declaration | string | The actual document type declaration in use, e.g. <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> |
Exceptions
Exception | Condition |
---|---|
SqlException | |
ArgumentOutOfRangeException | |
CSInvalidSessionException | |
CSPermissionDeniedException | |
CSDocumentNotFoundException | |
CSException |
Content Studio permissions
Remarks
Remarks
See Also