<?php
// List of events
 $json = array();

 // Query that retrieves events
 $requete = 'SELECT * FROM se_evenement where start between "'.$_GET['start'].' 00:00:00" and "'.$_GET['end'].' 00:00:00" ORDER BY id';
/*  $requete = "SELECT * FROM se_evenement WHERE status!='end' ORDER BY id"; */

// connection to the database
require_once('4798945.php');
//require('../45789417/ref4780.php');

/*
$query= mysqli_query($requete);
$res = array();
while ($row = mysqli_fetch_assoc($query)) {
//	print_r($row);
	$res[] = $row;
}
echo json_encode($res);
die();
*/

 // Execute the query
 $resultat = $bdd->query($requete) or die(print_r($bdd->errorInfo()));
 // sending the encoded result to success page
 echo json_encode($resultat->fetchAll(PDO::FETCH_ASSOC));

?>
