User Tools

Site Tools


kurs:functions.php

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

kurs:functions.php [2014/09/10 21:22] (current)
Line 1: Line 1:
 +<​code>​
 +<?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";​
 +}
 +?>
 +</​code>​
kurs/functions.php.txt ยท Last modified: 2014/09/10 21:22 (external edit)