User Tools

Site Tools


kurs:functions.php
<?php

ini_set('display_errors', 1);

function dbconnect() {
  $db = oci_connect('hr', 'hr', 'orcl');
  # .
  # .  
  return $db;
 
}  


function print_table($table) {
print "<table border=1>\n";
foreach ($table as $row) {
  print "<tr>"; 
  foreach ($row as $cell) {
    if (!isset($cell)) {$cell = 'n/a'; }  	
    print "<td> $cell </td> ";
  }
  print "</tr>\n";
}

print "</table>\n";
}
?>
kurs/functions.php.txt · Last modified: 2014/09/10 21:22 (external edit)