<?php
/**
 * @copyright ONE/DEPO Project
 * @license   PHP License 3.01 <http://www.php.net/license/3_01.txt>
 */

/* vim: set expandtab tabstop=4 shiftwidth=4 softtabstop=4: */

/**
 * @package     [[]]
 * @author      Your Name <mail@example.com>
 * @access      public
 */
class Movie
{
    var $c;
    var $sc;

    /**
     * @access  public
     */
    function execute()
    {
        $log =& LogFactory::getLog();
        $log->debug("Movie", "Movie#execute");


        if (!empty($this->c) && !empty($this->sc)){
            $mov = IMAGE_DIR ."/8/". $this->c ."_". $this->sc;
            foreach (glob($mov ."*", GLOB_NOSORT) as $movfile);
            if (is_file($movfile)){
                header ("Content-type: video/x-flv");
                ob_clean();
                flush();
                readfile($movfile);
                exit;
            }
        } else {
            exit;
        }
    }
}
?>
