downloads | documentation | faq | getting help | mailing lists | licenses | wiki | reporting bugs | php.net sites | links | conferences | my php.net

search for in the

Our source is open

The syntax highlighted source is automatically generated by PHP from the plaintext script. If you're interested in what's behind the several functions we used, you can always take a look at the source of the following files:

Of course, if you want to see the source of this page, we have it available. You can also browse the SVN repository for this website on svn.php.net.

Source of: /manual/en/function.xml-set-end-namespace-decl-handler.php

<?php
include_once $_SERVER['DOCUMENT_ROOT'] . '/include/shared-manual.inc';
$TOC = array();
$PARENTS = array();
include_once
dirname(__FILE__) ."/toc/ref.xml.inc";
$setup = array (
 
'home' =>
  array (
   
0 => 'index.php',
   
1 => 'PHP Manual',
  ),
 
'head' =>
  array (
   
0 => 'UTF-8',
   
1 => 'en',
  ),
 
'this' =>
  array (
   
0 => 'function.xml-set-end-namespace-decl-handler.php',
   
1 => 'xml_set_end_namespace_decl_handler',
  ),
 
'up' =>
  array (
   
0 => 'ref.xml.php',
   
1 => 'XML Parser Functions',
  ),
 
'prev' =>
  array (
   
0 => 'function.xml-set-element-handler.php',
   
1 => 'xml_set_element_handler',
  ),
 
'next' =>
  array (
   
0 => 'function.xml-set-external-entity-ref-handler.php',
   
1 => 'xml_set_external_entity_ref_handler',
  ),
);
$setup["toc"] = $TOC;
$setup["parents"] = $PARENTS;
manual_setup($setup);

manual_header();
?>
<div id="function.xml-set-end-namespace-decl-handler" class="refentry">
 <div class="refnamediv">
  <h1 class="refname">xml_set_end_namespace_decl_handler</h1>
  <p class="verinfo">(PHP 4 &gt;= 4.0.5, PHP 5)</p><p class="refpurpose"><span class="refname">xml_set_end_namespace_decl_handler</span> &mdash; <span class="dc-title">Set up end namespace declaration handler</span></p>

 </div>

 <a name="function.xml-set-end-namespace-decl-handler.description"></a><div class="refsect1 description">
  <h3 class="title">Description</h3>
  <div class="methodsynopsis dc-description">
   <span class="type">bool</span> <span class="methodname"><b>xml_set_end_namespace_decl_handler</b></span>
    ( <span class="methodparam"><span class="type">resource</span> <tt class="parameter">$parser</tt></span>
   , <span class="methodparam"><span class="type"><a href="language.pseudo-types.php#language.types.callback" class="type callback">callback</a></span> <tt class="parameter">$handler</tt></span>
   )</div>

  <p class="para rdfs-comment">
   Set a handler to be called when leaving the scope of a namespace
   declaration. This will be called, for each namespace declaration, after
   the handler for the end tag of the element in which the namespace was
   declared.
  </p>
 </div>


 <a name="function.xml-set-end-namespace-decl-handler.parameters"></a><div class="refsect1 parameters">
  <h3 class="title">Parameters</h3>
  <p class="para">
   </p><dl>

    <dt class="varlistentry">

     <span class="term"><i><tt class="parameter">parser</tt></i>
</span>

     </dt><dd class="listitem">

      <p class="para">
       A reference to the XML parser.
      </p>
     </dd>

   
    <dt class="varlistentry">

     <span class="term"><i><tt class="parameter">handler</tt></i>
</span>

     </dt><dd class="listitem">

      <p class="para">
       <i><tt class="parameter">handler</tt></i>
 is a string containing the name of a
       function that must exist when <a href="function.xml-parse.php" class="function">xml_parse()</a> is called
       for <i><tt class="parameter">parser</tt></i>
.
      </p>
      <p class="para">
       The function named by <i><tt class="parameter">handler</tt></i>
 must accept
       three parameters, and should return an integer value. If the
       value returned from the handler is <b><tt class="constant">FALSE</tt></b> (which it will be if no
       value is returned), the XML parser will stop parsing and
       <a href="function.xml-get-error-code.php" class="function">xml_get_error_code()</a> will return
       <b><tt class="constant">XML_ERROR_EXTERNAL_ENTITY_HANDLING</tt></b>.
       <div class="methodsynopsis dc-description">
         <span class="methodname"><span class="replaceable">handler</span></span>
         ( <span class="methodparam"><span class="type">resource</span> <tt class="parameter">$parser</tt></span>
        , <span class="methodparam"><span class="type">string</span> <tt class="parameter">$user_data</tt></span>
        , <span class="methodparam"><span class="type">string</span> <tt class="parameter">$prefix</tt></span>
        )</div>

       </p><dl>

        <dt class="varlistentry">

         <span class="term"><i><tt class="parameter">parser</tt></i>
</span>

         </dt><dd class="listitem">

          <span class="simpara">
           The first parameter, <span class="replaceable">parser</span>, is a
           reference to the XML parser calling the handler.
          </span>
         </dd>

       
        <dt class="varlistentry">

         <span class="term"><i><tt class="parameter">user_data</tt></i>
</span>

         </dt><dd class="listitem">

          <span class="simpara">
          </span>
         </dd>

       
        <dt class="varlistentry">

         <span class="term"><i><tt class="parameter">prefix</tt></i>
</span>

         </dt><dd class="listitem">

          <span class="simpara">
          </span>
         </dd>

       
       </dl>
<p>
      </p>
      <p class="para">
       If a handler function is set to an empty string, or <b><tt class="constant">FALSE</tt></b>, the handler
       in question is disabled.
      </p>
      <blockquote><p><b class="note">Note</b>: <span class="simpara">Instead of a function name, an
array containing an object reference and a method name can also be
supplied.</span></p></blockquote>
     </dd>

   
   </dl>
<p>
  </p>
 </div>


 <a name="function.xml-set-end-namespace-decl-handler.returnvalues"></a><div class="refsect1 returnvalues">
  <h3 class="title">Return Values</h3>
  <p class="para">
   Returns <b><tt class="constant">TRUE</tt></b> on success or <b><tt class="constant">FALSE</tt></b> on failure.
  </p>
 </div>


 <a name="function.xml-set-end-namespace-decl-handler.seealso"></a><div class="refsect1 seealso">
  <h3 class="title">See Also</h3>
  <p class="para">
   </p><ul class="simplelist">
    <li class="member"><a href="function.xml-set-start-namespace-decl-handler.php" class="function" rel="rdfs-seeAlso">xml_set_start_namespace_decl_handler()</a> - Set up start namespace declaration handler</li>
   </ul><p>
  </p>
 </div>


</div><?php manual_footer(); ?>
 
show source | credits | sitemap | contact | advertising | mirror sites