Update Table of Contence
$from";
if (($handle = fopen("filelist.csv", 'r')) !== false) {
while (($filelist[$fileNums] = fgetcsv($handle, 0, ',')) !== false) {
$fileNums++;
}
}
if ($to == 0 || $to >= $fileNums) {
$to = $fileNums - 1;
}
$FileName = $filelist[$from][1] . ".htm";
$fileId = $filelist[$from][0];
$fileId = $filelist[$from][0];
$dirLog = _DIR_LOG_ . "/";
$dirDb = "/";
$inputFileName = $FileName;
$outputFileNameHead = $filelist[$from][1];
$bookId = $filelist[$from][2];
$vriParNum = 0;
$wordOrder = 1;
$dirXmlBase = _DIR_PALI_CSV_ . "/";
$dirPaliTextBase = _DIR_PALI_HTML_ . "/";
$dirXml = $outputFileNameHead . "/";
$xmlfile = $inputFileName;
$log = $log . date("Y-m-d h:i:sa") . ",$from,$FileName,open\r\n";
$arrInserString = array();
// 打开csv文件并读取数据
$inputRow = 0;
if (($fp = fopen(_DIR_PALI_TITLE_ . "/" . ($from + 1) . "_{$_file}.csv", "r")) !== false) {
while (($data = fgetcsv($fp, 0, ',')) !== false) {
if ($inputRow > 0 && $data[3] != 100 && !empty($data[6])) {
array_push($arrInserString, $data);
}
$inputRow++;
}
fclose($fp);
echo "res load:" . _DIR_PALI_TITLE_ . "/" . ($from + 1) . "_title.csv
";
} else {
echo "can not open csv ";
if ($from == $to) {
echo "齐活!功德无量!all done!
";
} else {
echo "";
echo "正在载入:" . ($from + 1);
echo "