From 912398f2fb99b0d19dc016962d8fab0eee360f34 Mon Sep 17 00:00:00 2001 From: wailabualela Date: Tue, 29 Oct 2019 16:07:20 +0200 Subject: [PATCH] changes --- Customer.php | 21 +++++++-------------- Human.php | 4 +++- User.php | 9 +++++++++ 3 files changed, 19 insertions(+), 15 deletions(-) create mode 100644 User.php diff --git a/Customer.php b/Customer.php index 03ac184..bd31423 100644 --- a/Customer.php +++ b/Customer.php @@ -1,23 +1,17 @@ PHP OOP Sandbox "; -const BR = "
"; - - - +include './User.php'; +class Customer extends User +{ + var $customer_type; +} $kamal = new Customer; $kamal->frist_name = "Kamal"; $kamal->second_name = "Farouk"; -$kamal->birth_date['d'] = 23; -$kamal->birth_date['m'] = 7; -$kamal->birth_date['y'] = 1992; +$kamal->username = "kfarouk"; +$kamal->email = "kamalfarouk@mail.sd"; echo $kamal->full_name() . BR; @@ -25,4 +19,3 @@ class Customer extends Human // $omer->frist_name = "Omer"; // $omer->second_name = "Ali"; // echo $omer->full_name() . BR; - diff --git a/Human.php b/Human.php index 6bcc69b..ffb3e14 100644 --- a/Human.php +++ b/Human.php @@ -1,4 +1,7 @@ PHP OOP Sandbox "; +const BR = "
"; + class Human { var $first_name; @@ -16,4 +19,3 @@ function age() return ""; } } - diff --git a/User.php b/User.php new file mode 100644 index 0000000..8982f50 --- /dev/null +++ b/User.php @@ -0,0 +1,9 @@ +