diff --git a/src/export_articles.php b/src/export_articles.php
new file mode 100644
index 0000000..fd75f18
--- /dev/null
+++ b/src/export_articles.php
@@ -0,0 +1,90 @@
+prepare($sql);
+if ($stmt === false) {
+ die("Datenbankfehler.");
+}
+
+$all_params = array_merge($household_member_ids, [$current_user_household_id]);
+$all_types = $types . 'i';
+$stmt->bind_param($all_types, ...$all_params);
+$stmt->execute();
+$result = $stmt->get_result();
+
+header('Content-Type: text/csv; charset=utf-8');
+header('Content-Disposition: attachment; filename="artikel_export_' . date('Ymd_His') . '.csv"');
+
+$output = fopen('php://output', 'w');
+fprintf($output, chr(0xEF).chr(0xBB).chr(0xBF)); // BOM for Excel
+
+// Output headers
+$headers = [
+ 'Artikelname', 'Produktbezeichnung', 'Kategorie', 'Hersteller',
+ 'Gewicht (g)', 'Anzahl im Besitz', 'Verbrauchsartikel', 'Produkt-URL',
+ 'Lagerort (Ebene 1)', 'Lagerort (Ebene 2)', 'Ersteller'
+];
+fputcsv($output, $headers, ';');
+
+// Output rows
+while ($row = $result->fetch_assoc()) {
+ fputcsv($output, [
+ $row['Artikelname'],
+ $row['Produktbezeichnung'],
+ $row['Kategorie'],
+ $row['Hersteller'],
+ $row['Gewicht (g)'],
+ $row['Anzahl'],
+ $row['Verbrauchsartikel'],
+ $row['Produkt-URL'],
+ $row['Lagerort (Ebene 1)'],
+ $row['Lagerort (Ebene 2)'],
+ $row['Ersteller']
+ ], ';');
+}
+
+fclose($output);
+$stmt->close();
+$conn->close();
+?>
\ No newline at end of file
diff --git a/src/help.php b/src/help.php
index 7598ab9..92489c0 100644
--- a/src/help.php
+++ b/src/help.php
@@ -10,6 +10,7 @@ if (!isset($_SESSION['user_id'])) {
exit;
}
+require_once 'db_connect.php';
require_once 'header.php';
?>
diff --git a/src/todo_lists.php b/src/todo_lists.php
index 0289401..eed1aab 100644
--- a/src/todo_lists.php
+++ b/src/todo_lists.php
@@ -95,7 +95,7 @@ $active_list_id = isset($_GET['list_id']) ? intval($_GET['list_id']) : (!empty($
Meine Listen