// Trim spaces away
$sql = trim($sql);
+ // Is 'enable_codes' not set? Then set it to true
+ if (!isset($data['enable_codes'])) $data['enable_codes'] = true;
+
// Is there still a query left?
if (!empty($sql)) {
// Do we have an "ALTER TABLE" command?
if (substr(strtolower($sql), 0, 11) == 'alter table') {
// Analyse the alteration command
//* DEBUG: */ logDebugMessage(__FUNCTION__, __LINE__, "Alterting table: {$sql}");
- SQL_ALTER_TABLE($sql, __FUNCTION__, __LINE__);
+ SQL_ALTER_TABLE($sql, __FUNCTION__, __LINE__, $data['enable_codes']);
} else {
// Run regular SQL command
//* DEBUG: */ logDebugMessage(__FUNCTION__, __LINE__, "Running regular query: {$sql}");
- SQL_QUERY($sql, __FUNCTION__, __LINE__, false);
+ SQL_QUERY($sql, __FUNCTION__, __LINE__, $data['enable_codes']);
}
} // END - if
} // END - foreach