<base> Element

This element provides the information which is to be stored as attributes within the BASE tag between the HEAD tags of the Ephox EditLive! for Java document.  The element has only a HREF attribute.

The value which appears within the <base> element will appear within the actual EditLive! for Java document between the HEAD tags in a BASE tag.

Element Tree Structure

<editLiveForJava>
    <document>
        <html>
            <head>
                <base>

<editLiveForJava>
     <document>
         <html>
             <head>
                 <base ... />
                 ...
             </head>
             ...
         </html>
     </document>
     ...
</editLiveForJava>

Optional Attributes

Attribute Description
href This specifies the URL of a document whose server path is to be used as the base URL for all relative references in the document.

Example

The following example demonstrates how to specify the URL http://www.yourserver.com/ as the value for the base URL.

<editLiveForJava>
    <document>
        <html>
            <head>
                <base href="http://www.yourserver.com/"/>
                ...
            </head>
            ...
        </html>
    </document>
    ...
</editLiveForJava>

Remarks

If the <base> element is not specified then EditLive! for Java will use the base location of the page which it resides in as the base URL.  For example, if the instance of EditLive! for Java appeared in the page http://www.yourserver.com/editliveforjava.html then the instance of EditLive! for Java in that page will use http://www.yourserver.com as its base URL.

The <base> element can appear only once within the <head> element.

The <base> element must be a complete tag, it cannot contain a tag body.  Therefore the tag must be closed in the same line.  See the example below:

    <base href=... />

See Also