00001 <?php
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026
00027
00028
00029
00030
00031
00032
00033
00034 include_once( 'kernel/classes/datatypes/ezxmltext/handlers/output/ezxhtmlxmloutput.php' );
00035
00036 class eZPDFXMLOutput extends eZXHTMLXMLOutput
00037 {
00038
00039 function eZPDFXMLOutput( &$xmlData, $aliasedType, $contentObjectAttribute = null )
00040 {
00041 $this->eZXHTMLXMLOutput( $xmlData, $aliasedType, $contentObjectAttribute );
00042
00043 $this->OutputTags['table']['initHandler'] = 'initHandlerTable';
00044 $this->OutputTags['li']['initHandler'] = 'initHandlerLi';
00045 }
00046
00047 function initHandlerTable( &$element, &$attributes, &$sibilingParams, &$parentParams )
00048 {
00049 $ret = array();
00050
00051 if( !isset( $attributes['width'] ) )
00052 $attributes['width'] = '100%';
00053
00054 if( !isset( $attributes['border'] ) )
00055 $attributes['border'] = 1;
00056
00057 return $ret;
00058 }
00059
00060 function initHandlerLi( &$element, &$attributes, &$sibilingParams, &$parentParams )
00061 {
00062 if( !isset( $sibilingParams['list_count'] ) )
00063 $sibilingParams['list_count'] = 1;
00064 else
00065 $sibilingParams['list_count']++;
00066
00067 $ret = array( 'tpl_vars' => array( 'list_count' => $sibilingParams['list_count'],
00068 'tag_name' => $element->parentNode->nodeName ) );
00069 return $ret;
00070 }
00071
00072 var $TemplatesPath = 'design:content/datatype/pdf/ezxmltags/';
00073 }
00074
00075 ?>