Hellbringer mit seinem rauen Ton, wie man ihn kennt
War keine Verheimlichung mit Absicht:
Der Fehler kommt von der Zeile 6:
War keine Verheimlichung mit Absicht:
PHP-Code:
// Tabelle leeren
$clear_snippets = $ext_pdo->prepare("TRUNCATE TABLE snippets");
$clear_snippets->execute();
$sql_snippet = "SELECT * FROM snippets";
$stmt_snippet->execute();
foreach ($stmt_snippet as $row) {
$id = $row['id'];
$source = $row['source'];
$property_preprocess = $row['property_preprocess'];
$name = $row['name'];
$description = $row['description'];
$editor_type = $row['editor_type'];
$category = $row['category'];
$cache_type = $row['cache_type'];
$snippet = $row['snippet'];
$locked = $row['locked'];
$properties = $row['properties'];
$moduleguid = $row['moduleguid'];
$static = $row['static'];
$static_file = $row['static_file'];
$snippet = $ext_pdo->prepare("INSERT INTO htmlsnippets (id, source, property_preprocess, name, description, editor_type, category, cache_type, snippet, locked, properties, moduleguid, static, static_file)
VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?)");
$snippet->execute(array($id, $source, $property_preprocess, $name, $description, $editor_type, $category, $cache_type, $snippet, $locked, $properties, $moduleguid, $static, $static_file));
echo "<br>Snippet <b>$name</b> übertragen";
}
PHP-Code:
$stmt_snippet->execute();
PHP-Code:
Fatal error: Uncaught Error: Call to a member function execute() on null in.../script.php:6 Stack trace: #0 {main} thrown in ...script.php on line 6
Kommentar