From 32bfb0c10907146589ae41a707597c084b3ce636 Mon Sep 17 00:00:00 2001 From: Flatlogic Bot Date: Mon, 20 Apr 2026 06:12:47 +0000 Subject: [PATCH] adding user profile --- includes/header.php | 4 +- profile.php | 89 +++++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 92 insertions(+), 1 deletion(-) create mode 100644 profile.php diff --git a/includes/header.php b/includes/header.php index 8409c2c..cea649d 100644 --- a/includes/header.php +++ b/includes/header.php @@ -222,7 +222,9 @@ $isPublic = !empty($forcePublic) || !isset($user) || !$user; diff --git a/profile.php b/profile.php new file mode 100644 index 0000000..d3f4a3f --- /dev/null +++ b/profile.php @@ -0,0 +1,89 @@ +prepare($update_sql); + if ($stmt->execute($params)) { + // Update session data + $_SESSION['auth_user']['name_ar'] = $name_ar; + $_SESSION['auth_user']['name_en'] = $name_en; + set_flash('success', tr('تم تحديث الملف الشخصي بنجاح', 'Profile updated successfully')); + redirect_to('profile.php'); + } else { + set_flash('danger', tr('حدث خطأ أثناء التحديث', 'Error updating profile')); + } + } +} + +require_once __DIR__ . '/includes/header.php'; +?> + +
+
+
+
+
+ +
+

+

·

+
+
+
+ + +
+ + +
+ +
+
+ + +
+
+ + +
+
+ +
+ + +
+ +
+ +
+
+
+
+
+
+ +