<doc>
  <legacy_id>2210</legacy_id>
  <name>hostName</name>
  <type>function</type>
  <syntax>
    <example>the hostName</example>
    <example>hostName()</example>
  </syntax>
  <library></library>
  <objects>
  </objects>
  <synonyms>
  </synonyms>
  <classification>
    <category>Networks &amp; Communication</category>
  </classification>
  <references>
    <command tag="accept">accept Command</command>
    <function tag="DNSServers">DNSServers Function</function>
  </references>
  <history>
    <introduced version="1.0">Added.</introduced>
  </history>
  <platforms>
    <mac/>
    <windows/>
    <linux/>
    <ios/>
    <android/>
  </platforms>
  <classes>
    <desktop/>
    <server/>
    <web/>
    <mobile/>
  </classes>
  <security>
  </security>
  <summary><glossary tag="return">Returns</glossary> the <glossary tag="domain name">domain name</glossary> of the local system.</summary>
  <examples>
    <example>if the hostName is "localhost.example.org" then return empty</example>
  </examples>
  <description>
    <p>Use the <b>hostName</b> <control_st tag="function">function</control_st> to find the <glossary tag="domain name">domain name</glossary> of the computer that LiveCode is running on.</p><p/><p><b>Value:</b></p><p>The <b>hostName</b> <control_st tag="function">function</control_st> <glossary tag="return">returns</glossary> the <glossary tag="domain name">domain name</glossary> of the computer.</p><p/><p><b>Comments:</b></p><p>The <b>hostName</b> <control_st tag="function">function</control_st> does a reverse <glossary tag="DNS">DNS</glossary> lookup on the <function tag="hostAddress">hostAddress</function> in order to find the <glossary tag="domain name">domain name</glossary>. This means that the computer must be connected to the Internet in order to use this <control_st tag="function">function</control_st>. If a connection to the Internet is not available, the <b>hostName</b> <control_st tag="function">function</control_st> <glossary tag="return">returns</glossary> an <href tag="../dictionary/error_message.xml">error message</href>.</p>
  </description>
</doc>