AddHostHeader


Definition

Create a host header (a pointer for a third-level domain name) in your Web hosting account.

Usage

Use this command to add a host header to your Web hosting account.

Use this command to set the www host header for your account if you want www.yourdomainname.com to resolve to a location other than the root directory of your Web hosting account.

Another common use for this command is to “branch” a domain name, for example, so that sales.example.com and service.example.com resolve to different pages.

Availability

All resellers have access to this command.

Implementation on eNom.com

Log on to webhostingteLog on to webhostingtest.ehost-services.com with Login ID resellwebid, password resellwebpw.

http://webhostingtest.ehost-services.com/websites/hostheader.asp?d=resellerdocs.com

The SAVE HOST HEADER SETTINGS button calls the AddHostHeader command.

Constraints

The query must meet the following requirements:

  • The login ID and password must be valid.
  • The Web hosting account must belong to this domain name account.
  • The domain header must already exist.

Input parameters

Build the query string using this syntax:

https://resellertest.enom.com/interface.asp? command=nameofcommand&uid=yourloginid&pw=yourpassword &paramname=paramvalue&nextparamname=nextparamvalue

 

Parameter Status Description MaxSize
UID

Required

Account login ID 20
PW

Required

Account password 20
HostAccount Required Web hosting account that the domain header is associated with. 14
SLD Required Second-level domain name (for example, enom inenom.com) 63
TLD Required Top-level domain name (extension) 15
HostName Required Host name; third-level domain name. For example, in sales.example.com, the host name is sales. 53
FilePath Optional Directory path where you want this host header to point. Path must start at root level; path can be forward slash— or backslash—delimited. If you do not supply this parameter,this host header will point to root. 254
ResponseType Optional Format of response. Options are Text (default), HTML, or XML. 4

Returned parameters and values

Parameter Description
Successful

Success status for creating a new host header.

Command

Name of command executed

ErrCount The number of errors if any occurred. If greater than 0 check the Err(1 to ErrCount) values.
Err(x) Error messages explaining the failure. These can be presented as is back to the client.
Done True indicates this entire response has reached you successfully.

Notes

  • The default response format is plain text. To receive the response in HTML or XML format, send ResponseType=HTML or ResponseType=XML in your request.
  • Check the return parameter ErrCount. If greater than 0 the transaction failed. The parameter Err(ErrCount) can be presented to the client. Otherwise process the returned parameters as defined above.

Example