00001 <?php 00002 00006 class GenExport_Do extends DynExportBase 00007 { 00008 public $sClass_do = "genExport_do"; 00009 public $sClass_main = "genExport_main"; 00010 public $sExportFileName = "genexport"; 00011 00016 protected $_sThisTemplate = "dynbase_do.tpl"; 00017 00025 public function nextTick( $iCnt ) 00026 { 00027 $iExportedItems = $iCnt; 00028 if ( $oArticle = $this->getOneArticle( $iCnt, $blContinue ) ) { 00029 $smarty = oxUtilsView::getInstance()->getSmarty(); 00030 $smarty->assign_by_ref( "linenr", $iCnt ); 00031 $smarty->assign_by_ref( "article", $oArticle ); 00032 $this->write( $smarty->fetch( "genexport.tpl", $this->getViewID() ) ); 00033 return ++$iExportedItems; 00034 } 00035 00036 return $blContinue; 00037 } 00038 00046 public function write( $sLine ) 00047 { 00048 $sLine = $this->removeSID( $sLine); 00049 00050 $sLine = str_replace( array("\r\n","\n"), "", $sLine); 00051 $sLine = str_replace( "<br>", "\n", $sLine); 00052 00053 fwrite( $this->fpFile, $sLine."\r\n"); 00054 } 00055 00056 }