HBCMS更多的中文手册参考:

host参数属性

DHTML文档教程

Sets or retrieves the hostname and port number of the location or url.

dhtml语法

htmln/a
scriptingobject.host [ = shost ]

dhtml可能的值

sHostString that specifies or receives the host name and port number.

The property is read/write. The property has no default value.

Expressions can be used in place of the preceding value(s), as of Microsoft® Internet Explorer 5. For more information, see about dynamic properties.

remarks

the host property is the concatenation of the hostname and port properties, separated by a colon (hostname:port). when the port property is null, the host property is the same as the hostname property.

the host property may be set at any time, although it is safer to set the href property to change a location. if the specified host cannot be found, an error is returned.

DHTML代码范例

This example function returns the host property of the current page location.

function getHost()
{
return document.location.host;
}

是否符合公共标准

There is no public standard that applies to this property.

Applies To

A, AREA, location