summaryrefslogtreecommitdiff
path: root/web-scripts/packages.php
blob: b8b5dda637b769654c92886be931635d02ff3e7d (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
<?php

  $mysql = new mysqli("localhost", "http", "http");
  if ($mysql->connect_error) {
    die("Connection to mysql database failed: " . $mysql->connect_error);
  }

  $result = $mysql -> query("SELECT * FROM buildmaster.binary_packages");
  if ($result -> num_rows > 0) {
    while($row = $result->fetch_assoc()) {
      foreach ($row as $key => $val) {
        print $key .": ".$val." - ";
      }
      print "<br>\n";
    }
  }

  print 'OK';

?>