setHead Property

Description

This property sets the content of EditLive! for Java between the <HEAD> tags.

Syntax

JavaScript object.setHead(strHead)

Parameters

strHead Required.  A string containing the text that will be the initial contents of the instance of EditLive! for Java between the <HEAD> and </HEAD> tags. 

Example

The following code creates an instance of EditLive! for Java and sets the initial contents of the document head to be <HEAD><TITLE>Example Head</TITLE><BASE href="http://www.ephox.com/" target="_TOP"></HEAD>.  

Note:  The string passed to the setHead property must be URL encoded or encoded using the JavaScript escape function.  The example below uses the JavaScript escape function. 

var editlivejava1;
editlivejava1 = new EditLiveJava("ELJApplet1","600","400");
editlivejava1.setHead(escape("<HEAD><TITLE>Example Head</TITLE><BASE href="http://www.ephox.com/" target="_TOP"></HEAD>"));

Remarks

The string passed to the setHead property must be URL encoded or encoded using the JavaScript escape function.

When using the setDocument property the document <HEAD> specified by the setHead property overwrites any information set in the <HEAD> of the document specified by the setDocument property.

The information specified in the EditLive! for Java XML Configuration Document in the <head> element overwrites any information specified for the document <HEAD> via either the setDocument or setHead properties.

See Also