Location: PHPKode > projects > mediaIndex > docs/ch04s02.html
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html><head><meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1"><title>File Handlers</title><link rel="stylesheet" href="style.css" type="text/css"><meta name="generator" content="DocBook XSL Stylesheets V1.48"><link rel="home" href="index.html" title="MediaIndexer Document Management System"><link rel="up" href="ch04.html" title="Chapter 4. Under The Hood"><link rel="previous" href="ch04.html" title="Chapter 4. Under The Hood"><link rel="next" href="ch04s03.html" title="Media Type Binding"></head><body text="black" link="#0000FF" vlink="#840084" alink="#0000FF"><div class="navheader"><table width="100%" summary="Navigation header"><tr><th colspan="3" align="center">File Handlers</th></tr><tr><td width="20%" align="left"><a accesskey="p" href="ch04.html">Prev</a> </td><th width="60%" align="center">Chapter 4. Under The Hood</th><td width="20%" align="right"> <a accesskey="n" href="ch04s03.html">Next</a></td></tr></table><hr></div><div class="sect1"><div class="titlepage"><div><h2 class="title" style="clear: both"><a name="id2770825"></a>File Handlers</h2></div></div><p>Within a <span class="emphasis"><i>group</i></span> exist many media files.  These
        files will likely need specific handling logic to have MediaIndexer display
        them properly.  These are known as <span class="emphasis"><i>File Handlers</i></span>.</p><p>File handler definition is identical to the media group definitions.
        Simply define a new handler constant with the name of the class for this
        handler.</p><div class="figure"><p><b>Figure 4.2. File Handler Definitions</b></p><pre class="programlisting">
        define("_HANDLER_DEFAULT",   "default");
        define("_HANDLER_ARCHIVE",   "archive");  
        define("_HANDLER_CODE",      "code");
      </pre></div><p>Each file handler class must extend the default handler class 
      <span class="emphasis"><i>defaultHandler</i></span>.</p></div><div class="navfooter"><hr><table width="100%" summary="Navigation footer"><tr><td width="40%" align="left"><a accesskey="p" href="ch04.html">Prev</a> </td><td width="20%" align="center"><a accesskey="u" href="ch04.html">Up</a></td><td width="40%" align="right"> <a accesskey="n" href="ch04s03.html">Next</a></td></tr><tr><td width="40%" align="left" valign="top">Chapter 4. Under The Hood </td><td width="20%" align="center"><a accesskey="h" href="index.html">Home</a></td><td width="40%" align="right" valign="top"> Media Type Binding</td></tr></table></div></body></html>
Return current item: mediaIndex