<?php
include("adm/conexao_e_agenda.php");
 session_save_path('./minhas_sessions/');
 ini_set('session.gc_maxlifetime', '28800');
  $a = session_id();
  if(empty($a)) session_start();
//echo "<br>session_id(): ".session_id();//."<br>COOKIE: ".$_COOKIE["PHPSESSID"];	 
  $session_id = session_id(); 


$retorno_pedido = $_GET['transaction_id'];

		 $sql="UPDATE pedidos SET status='1', transaction_id='$retorno_pedido' WHERE id_session='$session_id' ORDER BY id ASC";// AND CURDATE() BETWEEN $data_simul AND $data_simul 
         $result=mysqli_query($conexao,$sql) or die (mysqli_error($conexao));
		 mysqli_free_result($result);
		 mysqli_close($conexao);
exit();
?>
