server.host

NES2+Syntax

server.host

Description

The host property of the server object contains the server name, any sub-domain, and domain name of the Web server.

Example

Listing 8.133 writes the host of the server to the user's page.

Listing 8.133 Accessing the host Property
<SERVER>

// Write the host property to the user's page
write(server.host);

</SERVER>
						

Get Pure JavaScript now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.