PreviousNext
Help > API Functions > Job logs > i5_jobLog_list_close
i5_jobLog_list_close

 

Close handle received from i5_jobLog_list().

 

     bool i5_jobLog_list_close (resource list)

Parameters

 

 

list

Job list handle as returned by i5_jobLog_list.

 

Return

 

True if OK, false if failed.

 

I5_ERR_PHP_HDLDFT

256

No default connection found.

I5_ERR_PHP_OPTIONSTYPE

259

The type of " I5_OPTIONS_ALIAS" option must be x and not x

I5_ERR_PHP_OPTIONSNUMBER

260

Option number -1 is unknown.

I5_ERR_PHP_TYPEPARAM

262

Type of element x in parameter -1 must be y. Type z was provided.

 

 

Example

 

 

 /*Get job information given in the request parameters*/
$jobName = $_POST["jobName"];

$userName = $_POST["userName"];

$jobNumber = $_POST["jobNumber"];

 

$HdlJob = i5_jobLog_list(array(I5_JOBNAME=>$jobName,

I5_USERNAME=>$userName, I5_JOBNUMBER=>$jobNumber));

if (is_bool($HdlJob)){

 $ret = i5_error();

 print_r($ret);

} else {

 $continue = true;

 while($continue) {

  $data = i5_jobLog_list_read($HdlJob);

  if (is_bool($data)){

   if (i5_errno() != 14){

    $ret = i5_error();

    print_r($ret);

   }

   break;

  } else {

   echo " - ".$data[I5_LOBJ_MSGDTA]."<BR>";

   if (isset($data[I5_LOBJ_MSGHLP]))

    echo $data[I5_LOBJ_MSGHLP]."<BR>";

  }

 }

}
i5_jobLog_list_close(
$HdlJob);