function testind() { // $ind = new Indicator("http://localhost:8001/Nice1/t03/"); // $file = "indic.json"; // $JS = file_get_contents($file); // $json = json_decode($JS,true); // $ind->generatefromJson($json); // $Ind = new Indicator("http://localhost:8001/Nice1/trace1/"); // $TypeObsel = array ("Ouverture_Page","Click-Lien"); // $res = json_encode($Ind->balance('16-04-2014','17-04-2014',$TypeObsel)); // $res = json_encode($Ind->classification()); // var_export($res); $man = new Indicator_Manager('http://localhost:8001/Nice1/t03/'); $ind = $man->getIndicator('Recherche Google'); $I = new Indicator('http://localhost:8001/Nice1/t03/'); $res = $I->refresh($ind, '04-04-2014'); var_export($res); }
$manager = new Indicator_Manager($_POST['trace']); } $a = $manager->getIndicator($name); if (isset($_POST['trace'])) { $ind = new Indicator($_POST['trace']); } $res = $ind->refresh($a, $after, $before); $r = json_encode($res); echo $r; } if ($_POST['reason'] == 'share') { if (isset($_POST['trace'])) { $store = new Indicator_Store($_POST['trace']); $manager = new Indicator_Manager($_POST['trace']); if (isset($_POST['nameind'])) { $ind = $manager->getIndicator($_POST['nameind']); } $res = $store->addToStore($ind); } echo json_encode($res); } if ($_POST['reason'] == 'getForView') { if (isset($_POST['trace'])) { $manager = new Indicator_Manager($_POST['trace']); } if (isset($_POST['nameind'])) { $ind = $manager->getIndicatorForView($_POST['nameind']); } echo json_encode($ind); } }