Ver Mensaje Individual
  #1 (permalink)  
Antiguo 21/02/2014, 19:21
bantuito
 
Fecha de Ingreso: mayo-2008
Mensajes: 96
Antigüedad: 16 años
Puntos: 0
¿Como arreglar error Undefined index:id de este codigo?

Tengo este codigo :

<?php
include_once("php/dbconfig.php");
include_once("php/functions.php");
function getCalendarByRange($id){
try{
$db = new DBConnection();
$db->getConnection();
$sql = "select * from `jqcalendar` where `id` = " . $id;
$handle = mysql_query($sql);
//echo $sql;
$row = mysql_fetch_object($handle);
}catch(Exception $e){
}
return $row;
}
if($_GET["id"]){
$event = getCalendarByRange($_GET["id"]);
}
?>


Me da este error:

Notice: Undefined index:id in (ruta del archivo) on line 16

¿Se puede arreglar?
¿Alguien sabe como?

Gracias