Added example

-- 
Provided by Nicolas Wallace (nwallace@fyberstudios.com)

git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@325705 c90b9560-bf6c-de11-be94-00142212c4b1
This commit is contained in:
Philip Olson 2012-05-16 05:09:53 +00:00
parent 18e80b781b
commit d39f1fe8ad

View file

@ -52,6 +52,36 @@
</simplelist>
</para>
</refsect1>
<refsect1 role="examples">
&reftitle.examples;
<para>
<example>
<title><methodname>SolrQuery::deleteByQuery</methodname> example</title>
<programlisting role="php">
<![CDATA[
<?php
$options = array
(
'hostname' => SOLR_SERVER_HOSTNAME,
'login' => SOLR_SERVER_USERNAME,
'password' => SOLR_SERVER_PASSWORD,
'port' => SOLR_SERVER_PORT,
);
$client = new SolrClient($options);
//This will erase the entire index
$client->deleteByQuery("*:*");
$client->commit();
?>
]]>
</programlisting>
</example>
</para>
</refsect1>
</refentry>