3 switch ($_REQUEST['employeeId']) {
\r
9 "department"=>"Management",
\r
11 "telephone"=>"240-555-1287"
\r
13 if (true == $_SESSION['isAdmin']) {
\r
14 $employee['homeAddress'] = array(
\r
15 "street"=>"123 Bluebird Ct.",
\r
24 "firstName"=>"George",
\r
25 "lastName"=>"Loram",
\r
26 "department"=>"Sales",
\r
27 "title"=>"VP of Sales",
\r
28 "telephone"=>"240-555-1287"
\r
30 if (true == $_SESSION['isAdmin']) {
\r
31 $employee['homeAddress'] = array(
\r
32 "street"=>"283 N. Market St.",
\r
33 "city"=>"Frederick",
\r
41 "firstName"=>"Sally",
\r
42 "lastName"=>"Beogagi",
\r
43 "department"=>"Human Resources",
\r
44 "title"=>"Senior Hiring Agent",
\r
45 "telephone"=>"443-555-1220"
\r
47 if (true == $_SESSION['isAdmin']) {
\r
48 $employee['homeAddress'] = array(
\r
49 "street"=>"8923 Redwood St.",
\r
50 "city"=>"Ellicott City",
\r
58 "firstName"=>"Billy",
\r
59 "lastName"=>"Diarmaid",
\r
60 "department"=>"Human Resources",
\r
61 "title"=>"Hiring Agent",
\r
62 "telephone"=>"443-555-2890"
\r
64 if (true == $_SESSION['isAdmin']) {
\r
65 $employee['homeAddress'] = array(
\r
66 "street"=>"893 Madison St.",
\r
75 "firstName"=>"Bruno",
\r
76 "lastName"=>"Domingos",
\r
77 "department"=>"Technology",
\r
79 "telephone"=>"443-555-2890"
\r
81 if (true == $_SESSION['isAdmin']) {
\r
82 $employee['homeAddress'] = array(
\r
83 "street"=>"123 5th St.",
\r
84 "city"=>"Washington",
\r
90 echo json_encode($employee);
\r