-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathaction_add_complaints_student.php
More file actions
51 lines (41 loc) · 1.21 KB
/
Copy pathaction_add_complaints_student.php
File metadata and controls
51 lines (41 loc) · 1.21 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
<?php
require_once 'facade.php';
//echo $_POST["userID"];
class Complaints{
private $c_ID;
private $user_ID;
private $complaint;
#constructor
function __construct() {
$this->c_ID = "";
$this->user_ID = "";
$this->complaint= "";
}
function set_c_ID($id) {
$this->c_ID = $id;
}
function set_user_ID($id) {
$this->user_ID = $id;
}
function set_complaint($c) {
$this->complaint = $c;
}
function get_c_ID() {
return $this->c_ID;
}
function get_user_ID() {
return $this->user_ID;
}
function get_complaint() {
return $this->complaint;
}
}
$db_layer = new Technical_layer();
$complaint = new Complaints();
$complaint->set_c_ID($_POST["comp_id"]); //$_POST["comp_id"]
// $complaint->set_user_ID("u userID"); //$_POST["userID"]
$complaint->set_complaint($_POST["complaint"]); //$_POST["complaint"]
///////////////////////////////////// passing to technical layer ////////////////////////
$db_layer->add_complaint_ToDB($complaint->get_c_ID(), $complaint->get_complaint() )
// $db_layer->add_complaint_ToDB($complaint->get_c_ID(), $complaint->get_user_ID(), $complaint->get_complaint() )
?>