Changeset 89 for trunk/fill_database.php
- Timestamp:
- Feb 11, 2009, 7:49:33 PM (16 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/fill_database.php
r67 r89 62 62 { 63 63 echo('<br />'.$Group['Name'].'<br />'); 64 $DBCFile = new DBC Reader();65 $DBCFile-> loadDbc('dbc/'.$Group['DBCFileName'].'.dbc', $Group['DBCColumns']);66 $ItemCount = $DBCFile-> count();64 $DBCFile = new DBCFile(); 65 $DBCFile->OpenFile('dbc/'.$Group['DBCFileName'].'.dbc', $Group['DBCColumns']); 66 $ItemCount = $DBCFile->RecordCount(); 67 67 $NewCount = 0; 68 68 $Count = 0; 69 69 for($i = 0; $i < $ItemCount; $i++) 70 70 { 71 $ItemId = $DBCFile-> getUint($i, 0);71 $ItemId = $DBCFile->GetUint($i, 0); 72 72 $DbResult2 = $Database->SQLCommand('SELECT ID FROM '.$Group['TablePrefix'].' WHERE entry='.$ItemId.' AND Language=0'); 73 73 if(isset($DbResult2) and (mysql_num_rows($DbResult2) > 0)) … … 78 78 foreach($Group['Items'] as $GroupItem) 79 79 { 80 $ColumnsValues .= ', `'.$GroupItem['Column'].'`="'.addslashes($DBCFile-> getString($i, $GroupItem['DBCColumnIndex'])).'"';80 $ColumnsValues .= ', `'.$GroupItem['Column'].'`="'.addslashes($DBCFile->GetString($i, $GroupItem['DBCColumnIndex'])).'"'; 81 81 } 82 82 $ColumnsValues = substr($ColumnsValues, 2); … … 91 91 { 92 92 $Columns .= ', `'.$GroupItem['Column'].'`'; 93 $Values .= ', "'.addslashes($DBCFile-> getString($i, $GroupItem['DBCColumnIndex'])).'"';93 $Values .= ', "'.addslashes($DBCFile->GetString($i, $GroupItem['DBCColumnIndex'])).'"'; 94 94 } 95 95 //$Columns = substr($Columns, 2);
Note:
See TracChangeset
for help on using the changeset viewer.