cvs: peardoc /en/package/networking/net-dns intro.xml /en/package/networking/net-dns/net-dns-resolver rawQuery.xml
| From: | Eric Kilfoil | Date: | Sun, 10 Apr 2005 17:27:46 +0000 |
| Subject: | cvs: peardoc /en/package/networking/net-dns intro.xml /en/package/networking/net-dns/net-dns-resolver rawQuery.xml | ||
| Groups: | php.pear.doc | ||
| Request: | Send a blank email to pear-doc+get-5914@lists.php.net to get a copy of this message | ||
ekilfoil Sun Apr 10 13:27:46 2005 EDT
Added files:
/peardoc/en/package/networking/net-dns intro.xml
/peardoc/en/package/networking/net-dns/net-dns-resolver
rawQuery.xml
Log:
new rawQuery documentation
http://cvs.php.net/co.php/peardoc/en/package/networking/net-dns/intro.xml?r=1.1&p=1
Index: peardoc/en/package/networking/net-dns/intro.xml
+++ peardoc/en/package/networking/net-dns/intro.xml
<?xml version="1.0" encoding="iso-8859-1" ?>
<!-- $Revision: 1.1 $ -->
<refentry id="packages.networking.net-dns.intro">
<refnamediv>
<refname>Introduction</refname>
<refpurpose>
General purpose DNS querying and packet parsing
</refpurpose>
</refnamediv>
<refsect1 id="packages.networking.net-dns.intro.contrib">
<title>Contributors</title>
<para>
<itemizedlist>
<listitem><simpara>Eric Kilfoil</simpara></listitem>
<listitem><simpara>Sara Golemon</simpara></listitem>
<listitem><simpara>Thomas V.V. Cox</simpara></listitem>
<listitem><simpara>PEAR End-Users - Thanks</simpara></listitem>
</itemizedlist>
</para>
</refsect1>
<refsect1 id="packages.networking.net-dns.intro.desc">
<title>Description</title>
<para>
The <classname>Net_DNS</classname> class provides DNS packet manipulation
methods and the ability to send and receive packets to/from nameservers.
Any type of DNS packet can be created, including RFC 2136 style DNS UPDATE
packets.
</para>
<para>
The current list of supported RR types are:
<itemizedlist>
<listitem><simpara>A</simpara></listitem>
<listitem><simpara>AAAA</simpara></listitem>
<listitem><simpara>A</simpara></listitem>
<listitem><simpara>CNAME</simpara></listitem>
<listitem><simpara>HINFO</simpara></listitem>
<listitem><simpara>MX</simpara></listitem>
<listitem><simpara>NAPTR</simpara></listitem>
<listitem><simpara>NS</simpara></listitem>
<listitem><simpara>PTR</simpara></listitem>
<listitem><simpara>SOA</simpara></listitem>
<listitem><simpara>SRV</simpara></listitem>
<listitem><simpara>TSIG</simpara></listitem>
<listitem><simpara>TXT</simpara></listitem>
</itemizedlist>
</para>
</refsect1>
</refentry>
<!-- Keep this comment at the end of the file
Local variables:
mode: sgml
sgml-omittag:t
sgml-shorttag:t
sgml-minimize-attributes:nil
sgml-always-quote-attributes:t
sgml-indent-step:1
sgml-indent-data:t
sgml-parent-document:nil
sgml-default-dtd-file:"../../../../../manual.ced"
sgml-exposed-tags:nil
sgml-local-catalogs:nil
sgml-local-ecat-files:nil
End:
vim600: syn=xml fen fdm=syntax fdl=2 si
vim: et tw=78 syn=sgml
vi: ts=1 sw=1
-->
http://cvs.php.net/co.php/peardoc/en/package/networking/net-dns/net-dns-resolver/rawQuery.xml?r=1.1&p=1
Index: peardoc/en/package/networking/net-dns/net-dns-resolver/rawQuery.xml
+++ peardoc/en/package/networking/net-dns/net-dns-resolver/rawQuery.xml
<!-- $Revision: 1.1 $ -->
<refentry id="package.networking.net-dns.net-dns-resolver.rawQuery">
<refnamediv>
<refname>Net_DNS_Resolver::rawQuery()</refname>
<refpurpose>Queries a nameserver and returns a response</refpurpose>
</refnamediv>
<refsynopsisdiv>
<funcsynopsis>
<funcsynopsisinfo>
require_once('Net/DNS.php');
</funcsynopsisinfo>
<funcprototype>
<funcdef>Net_DNS_Packet
<function>Net_DNS_Resolver::rawQuery</function></funcdef>
<paramdef>string <parameter>$hostname</parameter></paramdef>
<paramdef>string <parameter><optional>$type =
'A'</optional></parameter></paramdef>
<paramdef>string <parameter><optional>$class =
'IN'</optional></parameter></paramdef>
</funcprototype>
</funcsynopsis>
</refsynopsisdiv>
<refsect1 id="package.networking.net-dns.net-dns-resolver.rawQuery.desc">
&title.desc;
<para>
The <function>Net_DNS_Resolver::rawQuery</function>
function performs a DNS query similar to the
<link
linkend="package.networking.net-dns.net-dns-resolver.query">Net_DNS_Resolver::query()</link>
function; however, rawQuery() will return any response
from the nameserver. This is useful when the response
packet may or may not contain any resource records in the
"ANSWER" section.
</para>
<para>
rawQuery() uses the same resolver configuration used by
<link
linkend="package.networking.net-dns.net-dns-resolver.query">Net_DNS_Resolver::query()</link>.
</para>
</refsect1>
<refsect1 id="packages.networking.net-dns.net-dns-resolver.rawQuery.example">
&title.example;
<example>
<title>Using <function>Net_DNS_Resolver::rawQuery</function></title>
<programlisting role="php">
<![CDATA[
<?php
require_once 'Net/DNS.php';
$resolver = new Net_DNS_Resolver();
$response = $resolver->rawQuery('example.com');
if ($response) {
if (count($response->answer)) {
foreach ($response->answer as $rr) {
$rr->display();
}
}
}
?>]]>
</programlisting>
<para>
Output:
</para>
<screen>
<![CDATA[
example.com. 129808 IN A 192.0.34.166]]>
</screen>
</example>
</refsect1>
<refsect1 id="package.networking.net-dns.net-dns-resolver.rawQuery.note">
&title.note;
¬e.notstatic;
</refsect1>
</refentry>
<!-- Keep this comment at the end of the file
Local variables:
mode: sgml
sgml-omittag:t
sgml-shorttag:t
sgml-minimize-attributes:nil
sgml-always-quote-attributes:t
sgml-indent-step:1
sgml-indent-data:t
sgml-parent-document:nil
sgml-default-dtd-file:"../../../../manual.ced"
sgml-exposed-tags:nil
sgml-local-catalogs:nil
sgml-local-ecat-files:nil
End:
vim600: syn=xml fen fdm=syntax fdl=2 si
vim: et tw=60 syn=sgml
vi: ts=1 sw=1
-->