-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathfakeData.php
73 lines (68 loc) · 1.83 KB
/
fakeData.php
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
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
<?php
header('Content-Type: application/json ; charset=utf-8');
$first_name="";
$last_name="";
$year_birth="";
$year_missing="";
$gender="";
$height="";
$location="";
$additional_information="";
if(isset($_REQUEST['first_name']))
{
$first_name= trim($_REQUEST['first_name']);
}
if(isset($_REQUEST['last_name']))
{
$last_name= trim($_REQUEST['last_name']);
}
if(isset($_REQUEST['year_birth']))
{
$year_birth= trim($_REQUEST['year_birth']);
}
if(isset($_REQUEST['year_missing']))
{
$year_missing= trim($_REQUEST['year_missing']);
}
if(isset($_REQUEST['gender']))
{
$gender= trim($_REQUEST['gender']);
}
if(isset($_REQUEST['height']))
{
$height= trim($_REQUEST['height']);
}
if(isset($_REQUEST['location']))
{
$location= trim($_REQUEST['location']);
}
if(isset($_REQUEST['additional_information']))
{
$additional_information= trim($_REQUEST['additional_information']);
}
$output=array();
$output[0]["first_name"]="Anirudh";
$output[0]["last_name"]="Koul";
$output[0]["year_birth"]="1985";
$output[0]["year_missing"]="1999";
$output[0]["gender"]="m";
$output[0]["height"]="";
$output[0]["location"]="New Delhi, India";
$output[0]["additional_information"]="Brown Eyes";
$output[0]["photo_url"]="http://m.c.lnkd.licdn.com/media/p/1/000/00d/0a9/1581aed.jpg";
$output[0]["match_probability"]="0.8";
$output[1]["first_name"]="Happy";
$output[1]["last_name"]="Joe";
$output[1]["year_birth"]="1993";
$output[1]["year_missing"]="2001";
$output[1]["gender"]="f";
$output[1]["height"]="";
$output[1]["location"]="abu dhabi";
$output[1]["additional_information"]="";
$output[1]["photo_url"]="http://m.c.lnkd.licdn.com/mpr/mpr/shrink_200_200/p/3/000/2a1/0c6/2a46767.jpg";
$output[1]["match_probability"]="0.5";
$bigOutput["ServiceName"]="OrphanLocator";
$bigOutput["Value"]=$output;
$json_output=json_encode($bigOutput);
echo $json_output;
?>