Changeset 1883

Show
Ignore:
Timestamp:
2006-01-26 15:08:56 (3 years ago)
Author:
ctford
Message:

Switched to putting all annodex and cmml outputting functions in the one file.

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • Anode/trunk/acidfree/class_anode.inc

    r1880 r1883  
    6767        $media_location = _acidfree_filemanager_url($node->large,true); 
    6868        $anx_stub = '<?php 
    69                 $media_file = "'.$media_location.'"
    70                 require_once("../../../modules/output_annodex.php");'; 
     69                require_once("../../../modules/output_annodex.php")
     70                output_annodex( "'.$media_location.'" )'; 
    7171                //FIXME this kind of path hardcoding can't be good. 
    7272         
     
    7979        //FIXME maybe just define the node id? 
    8080        $cmml_stub = '<?php 
    81                 $media_file = "'.$media_location.'"
    82                 require_once("../../../modules/output_cmml.php");'; 
     81                require_once("../../../modules/output_annodex.php")
     82                output_cmml( "'.$media_location.'" )'; 
    8383                //FIXME this kind of path hardcoding can't be good. 
    8484         
  • Anode/trunk/acidfree/output_annodex.php

    r1880 r1883  
    77require_once("phpannodex/AnnodexWriter.php"); 
    88 
    9 $anx = new AnnodexWriter(); 
    10 $anx->import($media_file,NULL,NULL,0,-1); 
     9function output_annodex( $media_file, $output_headers=TRUE ) { 
     10        $anx = new AnnodexWriter(); 
     11        $anx->import($media_file,NULL,NULL,0,-1); 
    1112 
    12 while( $buffer = $anx->write_output() ) { 
     13       while( $buffer = $anx->write_output() ) { 
    1314                echo $buffer; 
     15        } 
     16 
     17        $anx->close(); 
     18        return; 
    1419} 
    1520 
    16 $anx->close(); 
    17 return; 
     21function output_cmml( $cmml_file, $output_headers=TRUE ) { 
     22         
     23        echo "This is pretty CMML"; 
     24        return; 
     25
    1826 
     27function output_cmml_headers() { 
     28         
     29        return; 
     30} 
     31 
     32function output_annodex_headers( AnnodexWriter $anx ) { 
     33         
     34        return; 
     35} 
     36