This repository was archived by the owner on Aug 3, 2019. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathgetData.php
More file actions
61 lines (55 loc) · 1.51 KB
/
getData.php
File metadata and controls
61 lines (55 loc) · 1.51 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
52
53
54
55
56
57
58
59
60
61
<?php
$v = "";
$let = "";
$desc = "";
$lenght = 0;
$input = $_GET['input'];
$type = $_GET['type'];
$margin = $_GET['margin'];
$show_top_level_pathways = $_GET['show_top_level_pathways'];
$matching_type = $_GET['matching_type'];
/* echo $input."\n";
echo $type."\n";
echo $margin."\n";
echo $show_top_level_pathways."\n";
echo $matching_type."\n";*/
include "restReader.php";
/*$header_data = array(
"input"=>"P00519|P31749|P11274|P22681|P22681|P16220|P46109|P27361|Q9UQC2",
"type"=>"uniprotList",
"margin"=>"3",
"show_top_level_pathways"=>"true",
"matching_type"=>"FLEXIBLE");
*/
$header_data = array(
"input"=>"$input",
"type"=>"$type",
"margin"=>"$margin",
"show_top_level_pathways"=>"$show_top_level_pathways",
"matching_type"=>"$matching_type");
//print_r ($header_data);
$responseP = CallAPI("GET", "http://localhost:8080/pathwayanalysis/bioinformaticsoft/v1_0/analysis", false, $header_data);
$obj = json_decode($responseP);
//echo $responseP;
//$items = $obj->items;
/* $i = 0;
foreach ($obj as $key2){
if ($i > 0){
if (is_numeric($key2->no_of_entities_found) && $key2->no_of_entities_found >= 0){
if ($v != ""){
$v=$v.",";
$let= $let.",";
$desc= $desc.",";
}
$let = $let."'".$key2->pathway_identifier."'";
$v = $v.$key2->no_of_entities_found;
$desc = $desc."'".$key2->pathway_name."'";
//echo $key2->pathway_name." ".$key2->pathway_identifier."<br>";
}
}
$i++;
//if ($i==10)break;
}
$lenght = $i;*/
echo json_encode($obj);
?>